View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Chris Hoffman Chris Hoffman is offline
external usenet poster
 
Posts: 2
Default Setting a formula using VBA

Phill,
Try this: .FormulaR1C1 = "the formula you want"

HTH
Chris Hoffman

"Phill" wrote in message
...
How do I set a cell to be a formula using VBA? I have
tried the following:
PNLWorksheet.Cells(lngDown, 9).Formula = "=" &
PNLWorksheet.Cells(lngDown, 8).Value & "/" &
PNLWorksheet.Cells(lngDenominator, 8)