LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 39
Default Insert formula to range of rows (Variable) from macro - debug help

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
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Using Debug.Print with Range Variable with more than one cell ExcelMonkey Excel Programming 3 April 7th 09 07:37 PM
Macro to insert a formula based on a range MarcusA Excel Discussion (Misc queries) 1 December 8th 06 09:26 AM
Need to insert formula to a variable number of rows edoc abv Excel Programming 1 September 26th 05 04:12 AM
Macro to insert formula result into range with zero values in cell JPS Excel Programming 9 July 6th 05 05:56 AM
insert variable number of rows tina Excel Programming 1 February 9th 05 01:18 PM


All times are GMT +1. The time now is 06:13 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"