Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
This must be simple...
I want to iterate across all cells in the second column of a named range ("Data_Range"). The following For-Each does not work... For Each cell In Range("Data_Range").Columns(2) Debug.Print cell.Address Next cell For each iteration, this prints the address of the entire named range, not the address of each cell in the range. Why is that? The following works using the single-parameter version of Cells()... For i = 1 To Range("Data_Range").Columns(2).Cells.Count Debug.Print Range("Data_Range").Columns(2).Cells(i).Value Next I Steve |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Named Range Links not working | Links and Linking in Excel | |||
My Dynamic Named Range isn't working | Excel Worksheet Functions | |||
Formula not working when letter A is used in a named range | Excel Discussion (Misc queries) | |||
working with a named range | Excel Programming | |||
Create named range for each column not working? | Excel Programming |