My question is quite simple but it drives me nuts!
Cell AN10, i.e. row 10 and column 40 contains the value 8. I am reading it into the integer Time using the VBA code
Time = Cells(4,3).Offset(6,37)
However the result is Time = 3, wich happens to be the value in cell AO10, i.e. cell(10,41). I have tried
Time = Cells(4,col)Offset(6,40 - col)
for values of col between 1 and 40 and I get the correct value 8 except for col = 3 and col = 38.
Is it a VBA bug or am I missing something very, very basic?
Thanks for any an help.
Cell AN10, i.e. row 10 and column 40 contains the value 8. I am reading it into the integer Time using the VBA code
Time = Cells(4,3).Offset(6,37)
However the result is Time = 3, wich happens to be the value in cell AO10, i.e. cell(10,41). I have tried
Time = Cells(4,col)Offset(6,40 - col)
for values of col between 1 and 40 and I get the correct value 8 except for col = 3 and col = 38.
Is it a VBA bug or am I missing something very, very basic?
Thanks for any an help.