I have a dataGridView that has 3 columns: SystemId, FirstName, LastName that is bound using database information. I would like to highlight a certain row, which I would do
If you just want to check if that item exists:
IEnumerable rows = grdPdfs.Rows .Cast() .Where(r => r.Cells["SystemId"].Value.ToString().Equals(searchValue)); if (rows.Count() == 0) { // Not Found } else { // Found }