PDA

View Full Version : Pasting a function to be in edit mode in a cell in excel



sikiswani
04-08-2015, 03:44 PM
Hi
I have a part of my menu that pastes function to the cell waiting for user to continue filling the parameters of the function.

for example: a function called myFunction. when I choose from menu I want that function to be in the cell as "=myFunction(" and the user continues from there

I used this code and it is working fine but I feel that there is another better way.




ActiveCell.FormulaR1C1 = "myFunction("

SendKeys "{F2}{home}={end}"