Matching the values of Split string in if condition
问题 What I'm trying to achieve is to match the Source doc no. of PER SAWT to P ER MAP . If it matches it will automatically check the CheckBox and it will set the BackColor to Color.Yellow . But when I try to split the Source Doc in PER MAP , it will only get the 2nd Value which is BS091 as per screenshot in 1st Scenario. My code work in 2nd scenario. 1st Scenario 2nd Senario Here is the code: For x As Integer = 0 To Me.DataGridView4.Rows.Count - 1 Dim sdoc_sawt As String = DataGridView4.Rows(x)