Hi Dave,
I got it now... Any way i need to put in a code for dynamically changing the
range and can do it
Thanks a lot
Regards
Habeeb
From: davebonall...@hotmail.com
To: excel-macros@googlegroups.com
Subject: $$Excel-Macros$$ Re: formula in macros
Date: Fri, 15 May 2009 17:0
Hi Guys,
I currently written a code were in total will be populated by adding various
sub totals. But I am not able to put in the formula for adding for future
reference. I am not able to think a logic for that.
I have explained my requirement in the attachement.
Please help me
Just try this
Worksheets("RAW").Range("A4701:CE4900").Copy _
Destination:=Worksheets("ExecServices").Range("A" & iNextRow&":CE" &
iNextRow)
> Date: Thu, 23 Apr 2009 10:54:34 -0700
> Subject: $$Excel-Macros$$ Macro Help
> From: dustin.ho...@gmail.com
> To: excel-macros@googlegroups.com
>
This could should work
Sub insert()
i = 1
Do
If Range("A" & i).Value = "" Then Exit Do
If Range("A" & i + 1).Value - Range("A" & i).Value > 1 Then
m = Range("A" & i + 1).Value - Range("A" & i).Value
Range("A" & i + 1).Select
l = i + 1
For k = 1 To m - 1
Range("A" & l).Select