R
RMO
I used the following in my code:
Range("G2").Select
Range("G2").Formula = "=IF(C2+E2>0,1,IF(E2>0,1,""""))"
Dim lastrow As Long
lastrow = Cells(Rows.Count, "C").End(xlUp).Row
Range("G2").AutoFill Range("g2:g" & lastrow)
The formula is dragged down the column and the rows in the formula change
yet the value is simply that of G2 all the way down. Only when I select the
cell and press enter will it read accurately. It seems this is more an excel
issue than a VBA one since I get the same results when entering any simple
formula manually.
Thanks
Range("G2").Select
Range("G2").Formula = "=IF(C2+E2>0,1,IF(E2>0,1,""""))"
Dim lastrow As Long
lastrow = Cells(Rows.Count, "C").End(xlUp).Row
Range("G2").AutoFill Range("g2:g" & lastrow)
The formula is dragged down the column and the rows in the formula change
yet the value is simply that of G2 all the way down. Only when I select the
cell and press enter will it read accurately. It seems this is more an excel
issue than a VBA one since I get the same results when entering any simple
formula manually.
Thanks