Home |
Search |
Today's Posts |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi
try somthing like sub foo() dim rng as range dim cell as range set rng = Range("Text_range") for each cell in rng if cell.value="your_test_value" then msgbox "Found value in cell: " cell.address end if next end sub -- Regards Frank Kabel Frankfurt, Germany Frood wrote: Hello all, I hope someboy can help with this, I have defined a name (Text_range) for a range of cells. I would like to write a macro that compares all cells in the range with a string. The reason I want to refer to the defined name for the cells is because the range is not continuous (=Results!$A$16:$A$84,Results!$A$86:$A$241...etc). Any help would be much appreciated. Ray |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Comparing text and then adding numbers if the text matches | Excel Worksheet Functions | |||
COMPARING TEXT IN A RANGE OF CELLS AND DISPLAY IT IN ANOTHER. | Excel Worksheet Functions | |||
Comparing a range of values | Excel Discussion (Misc queries) | |||
Comparing One Range and Adding Another | Excel Worksheet Functions | |||
Comparing a Range of Values | Excel Discussion (Misc queries) |