Home |
Search |
Today's Posts |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Barb, on a different note; were you able to sort out the SaveAs Event
"Barb Reinhardt" wrote: Try this Dim Rng As Excel.Range Dim myWS As Excel.Worksheet Set myWS = Worksheets("Calculate") Set Rng = myWS.Range("E2:E30") Rng.Formula = _ "=IF(ISBLANK(D3)=TRUE,""Blank"",IF(D3=$D$2+($D$2* 0.05)," & _ """Over"",IF(D3<=$D$2-($C$2*0.05),""Under"",""Pass"")))" -- HTH, Barb Reinhardt "fishy" wrote: I am getting a debug error 'Compile Error, Expected: end of statement' for the following formula insertion: Set Rng = Worksheets("Calculate").Range("E2:E30") Formula = "=IF(ISBLANK(D3)=TRUE,"Blank",IF(D3=$D$2+($D$2*0. 05),"Over",IF(D3<=$D$2-($C$2*0.05),"Under","Pass")))" Column B has a variable number of rows which I need to drag the formula down for so am putting rows 2-30 as there will never be more than this. Is there a better way of doing this? Any help appreciated |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Using Debug.Print with Range Variable with more than one cell | Excel Programming | |||
Macro to insert a formula based on a range | Excel Discussion (Misc queries) | |||
Need to insert formula to a variable number of rows | Excel Programming | |||
Macro to insert formula result into range with zero values in cell | Excel Programming | |||
insert variable number of rows | Excel Programming |