Hi All
I am working on a grid view where I have an acitve column which has radio button, user can select either yes or no for the active column. depending on the selection I am able to update the database.
I am using the code below to get the selected value of the row in the grid view
For i = 0 To Request.Form.Count - 1
Name = Request.Form.AllKeys(i)
If (Name.StartsWith("list")) Then
Value = Request.Form.GetValues(i)(0)
Array = itemName.Split("_")
Name = itemArray(1)
Now I want to check the grid view if atleast one row has active field set to "yes", If user selects all the rows to No I want to display an error instead of updating the database.
how can we check the entire grid view if atleast one row has active = yes
Thanks in advance
I am working on a grid view where I have an acitve column which has radio button, user can select either yes or no for the active column. depending on the selection I am able to update the database.
I am using the code below to get the selected value of the row in the grid view
For i = 0 To Request.Form.Count - 1
Name = Request.Form.AllKeys(i)
If (Name.StartsWith("list")) Then
Value = Request.Form.GetValues(i)(0)
Array = itemName.Split("_")
Name = itemArray(1)
Now I want to check the grid view if atleast one row has active field set to "yes", If user selects all the rows to No I want to display an error instead of updating the database.
how can we check the entire grid view if atleast one row has active = yes
Thanks in advance