I’m trying to create a macro to shade every other line in Libreoffice Calc.
Sub altRows
Dim i as integer
for i = 8 to 1001
Range(Cells(i , 1), Cells(i , 4)).Interior.Color = RGB(255, 255, 255)
i=i+1
Range(cells(i , 1), Cells(i , 4)).Interior.Color = RGB(217, 217, 217)
i=i+1
next
End sub
I’m getting an error BASIC runtime error.
Sub-procedure or function procedure not defined on the following line.
Range(Cells(i , 1), Cells(i , 4)).Interior.Color = RGB(255, 255, 255)
Any help would be appreciated