Mega Code Archive

 
Categories / VisualBasic Script / Excel
 

Entering a Formula in a Cell

'Enters the formula =SUM($G$12:$G$22) in the active cell: Sub fomula()     ActiveCell.Formula = "=SUM($G$12:$G$22)" End Sub