Posted on: 6/14/2013 5:51:05 AM | Views : 452

Dear All,
   i try to write a code when select the values, the status will auto change , but when i link the values with DB, it show out the Error, kindly ,advise, thakn you.
private void FillStatus() { WMWTLocator.Items.Clear(); WMWTStatus.Text = ""; string selectSQL = "SELECT STATUS_ID_SYS,STATUS_ID,STATUS_DESC FROM [AcmkIMS].[dbo].[IMS_STATUS_ID] WHERE STATUS_ID_SYS = 'WM' AND STATUS_ID = '" + WMWTLocator.SelectedItem.Value + "' "; SqlConnection con = new SqlConnection(System.Configuration.ConfigurationManager.ConnectionStrings["CIMProRPT01ConnectionString"].ConnectionString); SqlCommand cmd = new SqlCommand(selectSQL, con); SqlDataReader reader; try { con.Open(); reader = cmd.ExecuteReader(); while (reader.Read( ...

Go to the complete details ...