Forum Discussion
dentalior32
Apr 27, 2021Copper Contributor
macro command for function key F9
Hello I recorded a macro in Excel, one of the commands recorded in the macro was to calculate a formula (function key F9). When I opened the macro for editing, this was the line that appeared in th...
dentalior32
Apr 27, 2021Copper Contributor
Hi,
Thank you!!!
sadly Im still having trouble with that (sorry, just beginner...)
I'm not sure what's the Command syntax.
this in my Macro:
ActiveCell.FormulaR1C1 = "The price is set"
ActiveCell.Offset(0, 8).Range("A1").Select
ActiveCell.FormulaR1C1 = "2000"
ActiveCell.Offset(0, -8).Range("A1").Select
End Sub
The yellow line is my problem...
can you please show me the full syntax in order to calculate the selected cell?
TNX
HansVogelaar
Apr 27, 2021MVP
If both the active cell and the cell 8 columns to the right contain formulas:
ActiveCell.Calculate
ActiveCell.Offset(0, 8).Calculate