Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Still working on this code:
Sub CtyMatch() Dim strOrig, strOutcomes As String Dim rCell, rTOCtyLst As Range Dim iOrigCityNo, iEndRow As Integer strOrig = ActiveSheet.Range("A2") iOrigCityNo = Left(strOrig, 2) iEndRow = ActiveSheet.Range.Cells(Rows.Count, "B").End(xlUp).Row Set rTOCtyLst = Range(.Cells(1, 1), .Cells(1, iEndRow)) But am getting an "invalid or unqualified reference" error on the last line, .Cells being highlighted. I copied this line from another thread here so I'm stumped as to why it doesn't recognize ".Cells" here but does elsewhere in a nearly identical situation. Any suggestions? Thanks. |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Invalid cell reference | Excel Discussion (Misc queries) | |||
excel invalid reference | Excel Discussion (Misc queries) | |||
Invalid Reference in Chart | Charts and Charting in Excel | |||
Invalid Reference Message? | Excel Discussion (Misc queries) | |||
How do I fix an Invalid Reference? | New Users to Excel |