jemckinney
MIS
I just cannot get this to run. Senario: I have two drop down boxes. One is going to fill a value in the sql code for choosing the correct record, the second is what to change a value to.
strUpdate = "Update table Set OldStatus=@oldID Where ssn=@stuSSN and newstatus=@newID"
cmdUpdate = New SqlCommand( strUpdate, dbConn)
cmdUpdate.Parameters.Add( "@stuSSN", txtstuSSN.Text )
cmdUpdate.Parameters.Add( "@oldID", txtoldID.SelectedItem.Value )
cmdUpdate.Parameters.Add( "@newID", txtnewID.SelectedItem.Value )
Here is what my dropdown looks like:
<asp
ropDownList ID="txtoldID" Runat="Server">
<asp:ListItem Text="R" Value="R" />
<asp:ListItem Text="S" Value="S" />
</asp
ropDownList>
This one little tidbit is holding up from making the site live. So frustrating. When I run the page and enter the ssn and choose from the two dropdowns and click submit, it just reloads the same page and changes nothing. I get no error message or anything.
strUpdate = "Update table Set OldStatus=@oldID Where ssn=@stuSSN and newstatus=@newID"
cmdUpdate = New SqlCommand( strUpdate, dbConn)
cmdUpdate.Parameters.Add( "@stuSSN", txtstuSSN.Text )
cmdUpdate.Parameters.Add( "@oldID", txtoldID.SelectedItem.Value )
cmdUpdate.Parameters.Add( "@newID", txtnewID.SelectedItem.Value )
Here is what my dropdown looks like:
<asp
<asp:ListItem Text="R" Value="R" />
<asp:ListItem Text="S" Value="S" />
</asp
This one little tidbit is holding up from making the site live. So frustrating. When I run the page and enter the ssn and choose from the two dropdowns and click submit, it just reloads the same page and changes nothing. I get no error message or anything.