cmd.CommandText = "select tradeno from tblmultipletrade where pid = " & prodno
cmd.Connection = con.createConnection(Session("site"))
Dim dcheck As SqlDataReader
dcheck = cmd.ExecuteReader()
If dcheck.HasRows Then
While dcheck.Read()
Dim varCountTrade As Int32 = 0
For varCountTrade = 0 To dlstTrade.Items.Count - 1
Dim varItem As DataListItem = dlstTrade.Items(varCountTrade)
Dim varTradeno As Int32 = CType(varItem.FindControl("catid"), Label).Text
Dim intColIndex As Int32
For intColIndex = 0 To dcheck.FieldCount - 1
If varTradeno = dcheck.GetValue(intColIndex) Then
CType(varItem.FindControl("check"), CheckBox).Checked = True
End If
Next
Next
End While
End If
dcheck.Close()
cmd.Dispose()
Sunday, February 1, 2009
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment