Hi, i need to search all cells inside a dataviewgrid in VB.net starting with "www" , once i found one cell apply a background color to the complete row and get the next cell with the same String.
Part of my code:


Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
            Dim Ds1 As DataSet
            Dim SearchSt1 as String = "www"
            Ds1 = Session("SetDs")  'assigned one page before load
...some code
            GridViewReport.DataSource = Ds1.Tables(0) 
           ***Here i need to search in GridViewReport "Like" Searchst1 because i need all cells starting with "www" and set row.BackColor = Color.Lightblue***

...some code

End Sub

Any help will be appreciated.

I have found a solution, i'll paste code just in case that someone else need a solution like this.

Dim b, bb As Integer
            For b = 0 To GridViewReport.Rows.Count - 1
                For b = 0 To GridViewReport.Rows(0).Cells.Count - 1
                     If CStr(GridViewReport.Rows(b).Cells(bb).Text) =  SearchSt1 Then
                         GridViewReport.Rows(bb).BackColor = Color.LightGray
                     End If
This question has already been answered. Start a new discussion instead.