![]() |
FormulaR1C1
Is it possible to mix relative ranges with other ranges?
Thanks Sub DrillPipe1() With Range("RngVrtDp1") If ("RngVrtDp1") ("I3") Then ..FormulaR1C1 = "=(RC[-1])*(L9*0,01)" Else ..FormulaR1C1 = "=(RC[-1])" End If End With End Sub |
FormulaR1C1
Haven't tried but don't think so. I usually use regular
..formula="=a1*b1" -- Don Guillett SalesAid Software "Aksel Børve" wrote in message ... Is it possible to mix relative ranges with other ranges? Thanks Sub DrillPipe1() With Range("RngVrtDp1") If ("RngVrtDp1") ("I3") Then .FormulaR1C1 = "=(RC[-1])*(L9*0,01)" Else .FormulaR1C1 = "=(RC[-1])" End If End With End Sub |
FormulaR1C1
Aksel
No. Excel will put quotes around L9 and give you a #NAME? error. You can use Application.ConvertFormula to covert an A1 style reference to R1C1, though. -- Dick Kusleika Excel MVP Daily Dose of Excel www.dicks-blog.com Aksel Børve wrote: Is it possible to mix relative ranges with other ranges? Thanks Sub DrillPipe1() With Range("RngVrtDp1") If ("RngVrtDp1") ("I3") Then .FormulaR1C1 = "=(RC[-1])*(L9*0,01)" Else .FormulaR1C1 = "=(RC[-1])" End If End With End Sub |
All times are GMT +1. The time now is 04:52 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com