Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I need to select a range of cells knowing only the column index number (i)
So Range("C2:C12") needs to be Range("i2:i12"). I know there is the Cells command: like Cells(5, i).Select but this only selects one cell. I guess its a syntax problem for me. Ideally i need to select a range with variable for row and column..any tips ? |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
range(cells(2,i),cells(12,i)).select
However, you usually do NOT need to select to do what is needed and it is better NOT to select. -- Don Guillett SalesAid Software "David Andrews" wrote in message news:_8yai.167$%M5.6@trndny02... I need to select a range of cells knowing only the column index number (i) So Range("C2:C12") needs to be Range("i2:i12"). I know there is the Cells command: like Cells(5, i).Select but this only selects one cell. I guess its a syntax problem for me. Ideally i need to select a range with variable for row and column..any tips ? |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Cells(2, i).Resize(11).Select
-- HTH Bob (there's no email, no snail mail, but somewhere should be gmail in my addy) "David Andrews" wrote in message news:_8yai.167$%M5.6@trndny02... I need to select a range of cells knowing only the column index number (i) So Range("C2:C12") needs to be Range("i2:i12"). I know there is the Cells command: like Cells(5, i).Select but this only selects one cell. I guess its a syntax problem for me. Ideally i need to select a range with variable for row and column..any tips ? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Select number from leftmost column that has one | Excel Discussion (Misc queries) | |||
Select range using row and column number addresses | Excel Discussion (Misc queries) | |||
Select a column using it's number | Excel Programming | |||
How do I select the first occurance of a number in a column | Excel Programming | |||
Select same range from large number of workbooks | Excel Worksheet Functions |