Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hello there
I am quite often using functions such as ____________ For i = x to whatever CODE Next i ___________ but I would also like to use this kind of structure for columns such as For ? = A to J CODE Next ? But obviously its not this kind of structure anymore, do you know what to use? kind regards, Daniel |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Here's one way:
Dim Col As Range For Each Col In Range("A:F").Columns Col.ColumnWidth = 12 Next NickHK P.S. You know Excel version before the 207 Beta only have 256 columns, so you can't go as high as 1000. wrote in message ups.com... Hello there I am quite often using functions such as ____________ For i = x to whatever CODE Next i ___________ but I would also like to use this kind of structure for columns such as For ? = A to J CODE Next ? But obviously its not this kind of structure anymore, do you know what to use? kind regards, Daniel |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi Daniel,
Try something like: '============= Public Sub Tester() Dim i As Long For i = 1 To 20 Step 2 Columns(i).Interior.ColorIndex = 6 Next i End Sub '<<============= --- Regards, Norman wrote in message ups.com... Hello there I am quite often using functions such as ____________ For i = x to whatever CODE Next i ___________ but I would also like to use this kind of structure for columns such as For ? = A to J CODE Next ? But obviously its not this kind of structure anymore, do you know what to use? kind regards, Daniel |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Thats just great Nick, Norman!
many thanks for your help I am just testing all this but I am sure it will be just fine. Once again, thanks for your help Daniel Norman Jones wrote: Hi Daniel, Try something like: '============= Public Sub Tester() Dim i As Long For i = 1 To 20 Step 2 Columns(i).Interior.ColorIndex = 6 Next i End Sub '<<============= --- Regards, Norman wrote in message ups.com... Hello there I am quite often using functions such as ____________ For i = x to whatever CODE Next i ___________ but I would also like to use this kind of structure for columns such as For ? = A to J CODE Next ? But obviously its not this kind of structure anymore, do you know what to use? kind regards, Daniel |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
devide by 1000 | Excel Discussion (Misc queries) | |||
1000-200*4% add | Excel Discussion (Misc queries) | |||
1000 to 1 and 1 to 1000 | Excel Worksheet Functions | |||
1000+$K$5/1000 -what does $ indicate in formula | Excel Worksheet Functions | |||
Event ID 1000 | Excel Programming |