View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
excelent excelent is offline
external usenet poster
 
Posts: 695
Default Row number of a specific value

This one looks in column A

Sub color()

For r = 1 To 10
If Cells(r, 1).Interior.ColorIndex = 5 Then
MsgBox ("Row ") & r
End If
Next

End Sub


" skrev:

Hi,
How do I get the row number of a specific cell?
Lets suppose I have a column colour

Colour
black
blue
green

and I'd like to get the row number of the cell containing the value
blue.
How can I do it?

Thanks
Faby