Writing Formula to Cell
There is an Excel file that teaches how to perform the Writing Formula to Cell operation.
Excel Format: Writing Formula to Cell
This workbook demonstrates writing formula to cell using VBA macros on a 15-row data layout.
Hope it is useful.