View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 27,285
Default Create formulas with $Rn1Cn2:$Rn1Cn3 format

sStr = "=SUM(G10:G20)"
? application.ConvertFormula(sStr,xlA1,xlA1,xlAbsRow RelColumn)
=SUM(G$10:G$20)
? application.ConvertFormula(sStr,xlA1,xlA1,xlRelRow AbsColumn)
=SUM($G10:$G20)

--
Regards,
Tom Ogilvy


Michael D. Ober <[email protected] wrote in message
...
I need to have VBA create formulas with mixed referencing such as:

=SUM($G10:$G20)

I can create =SUM($G$10:$G$20) and =SUM(G10:G20), neither of which is what

I
need.

Thanks,
Mike.