I have an autofill VBA code to fill the cells from a formula. When I run the procedure, it did not autofill. However, when I step through the code, it did autofill each cells. I am not sure why it does not work when I run the procedure, but works when I step through the code one by one. Here is my code:
GAPDHNFormula = "=IF(RC[-14]>0.9,RC[-4]/RC[-14],RC[-4])"
wbOne.Worksheets(1).Range("AC10".Formula = GAPDHNFormula
Range("AC10".autofill Destination:=Range("AC10:AC88", Type:=xlFillDefault
wbOne is referring to the 1st workbook I have open, which I assigned the workbooks to object variables. Thank you!
GAPDHNFormula = "=IF(RC[-14]>0.9,RC[-4]/RC[-14],RC[-4])"
wbOne.Worksheets(1).Range("AC10".Formula = GAPDHNFormula
Range("AC10".autofill Destination:=Range("AC10:AC88", Type:=xlFillDefault
wbOne is referring to the 1st workbook I have open, which I assigned the workbooks to object variables. Thank you!