Hi vbforum users!

I need to rowcount in datagridview with a particular value.
My column "6" have the value that find, I try with the following code:

Code:
  Dim apc As Decimal = 0
For x As Integer = 0 To DataGridView3.RowCount - 1
            If DataGridView3.Rows(x).Cells(6).Value = "AP" Then
                apc = DataGridView3.Rows(x).Cells(6).Value.ToString.Count
            End If

        Next
textbox1.text=apc
any help, as welcome!!
Best Regards!!