Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Dont you count backwards with a for next loop using the following
For i = 1 To 4 Sheet1.Cells(i, 1) = i Next i I cant seem to get it to work. I also tried using a Step -1 but no luck Any ideas ? -- thank You Gus |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I think what you are wanting would be a for i = 4 to 1 step - 1
you were trying to step backward but increment at the same time. -- -John Please rate when your question is answered to help us and others know what is helpful. "Gus Chuch" wrote: Dont you count backwards with a for next loop using the following For i = 1 To 4 Sheet1.Cells(i, 1) = i Next i I cant seem to get it to work. I also tried using a Step -1 but no luck Any ideas ? -- thank You Gus |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Step -1 is the route!!
but you may need something like: Sub tester() With ActiveSheet For i = 4 To 1 Step -1 Sheets("Sheet1").Cells(i, 1) = i Next i End With End Sub "Gus Chuch" wrote: Dont you count backwards with a for next loop using the following For i = 1 To 4 Sheet1.Cells(i, 1) = i Next i I cant seem to get it to work. I also tried using a Step -1 but no luck Any ideas ? -- thank You Gus |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
For i = 4 to 1 step -1
"Gus Chuch" wrote: Dont you count backwards with a for next loop using the following For i = 1 To 4 Sheet1.Cells(i, 1) = i Next i I cant seem to get it to work. I also tried using a Step -1 but no luck Any ideas ? -- thank You Gus |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Count backwards N cells | Excel Worksheet Functions | |||
Loop backwards through selection? | Excel Programming | |||
Loop & Count | Excel Programming | |||
Count backwards | Excel Programming |