Home |
Search |
Today's Posts |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Keith R wrote:
Set cell = sheet.Cells.Find(label); sets your "cell" range to a specific cell where you found the first match Yes, this should find the first match of "label" on the sheet. cell = cell.Cells(1, 2) ' one cell to the right may set your range to a specific cell that doesn't include your match This is intended. The function looks for the first occurrence of the "label" argument, and then returns the value of the cell to the right of it. The point is that I do not want to *prevent* duplicate matches when the function is called more than once. Instead, I want to make it return the exact same result each time it is called with the same arguments. And, just by chance, I have come across the solution: If I change the line "cell = cell.Cells(1, 2)" to "Set cell = cell.Cells(1, 2)", then it works. Don't ask me why. Jens |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
How do I search for repeated numbers in same column | New Users to Excel | |||
How can I search for entries that are repeated in the workbook? | Excel Worksheet Functions | |||
copy from B worksheet to A worksheet with NO repeated data | Excel Discussion (Misc queries) | |||
how can i know that my worksheet having repeated same values | Excel Worksheet Functions | |||
Printing text in a repeated cell/row that is longer than repeated | Excel Discussion (Misc queries) |