here's a method..

Results 1 to 2 of 2

Thread: here's a method..

  1. #1
    Join Date
    Dec 1969

    Default here's a method..

    That I am creating. In my stored procedure I have updates my table by setting A column in the table equal to a binary value that is to be retreived from my application. This value is to be 0 if a checkbox is not selected and 1 if it is selected. How do i set parameters in my code so that my variable is equal to either 0 or 1 for each record in the datagrid?<BR><BR> Sub InsertData2()<BR> Dim selectedIndex As Integer<BR> Dim rsc as RowSelectorColumn = RowSelectorColumn.FindColumn(dg_approval)<BR><BR>F or Each selectedIndex in rsc.SelectedIndexes<BR><BR> Response.Write(selectedIndex.ToString())<BR> <BR> Dim conn as SQLConnection<BR> Conn = New SQLConnection(connstr)<BR> Dim Cmd1 as SqlCommand<BR> Cmd1 = New SQLCommand("approval",Conn)<BR> &#039;Declare the command type - a stored proc in this case<BR> Cmd1.commandType = CommandType.storedProcedure <BR> Cmd1.Parameters.Add("@SelIndex", rsc.SelectedIndexes.Length)<BR> response.write(rsc.Selectedindexes)<BR><BR> cmd1.ExecuteNonQuery()<BR> conn.Close()<BR>next<BR> end sub

  2. #2
    Join Date
    Dec 1969

    Default * Ignore. Troll.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts