I'm also trying it insert a row, but in my example, I want to insert
in after the "SubTotal" after using the "subtotal function" adding the
blank row after the subtotal line.  How would you modify the macro in
your example to accomplish this?

Dave

On Feb 26, 12:44 am, Mahesh parab <mahes...@gmail.com> wrote:
> Hi Jason
>
> find attach, hope this will help
> if u use left function then its matching with u r group criteria
>
> Sub Mxm()
> Dim LR As Long, i As Long
> LR = Range("A" & Rows.Count).End(xlUp).Row
> For i = LR To 3 Step -1
>     If Left(Range("A" & i).Value, 2) <> Left(Range("A" & i - 1).Value, 2)
> Then Rows(i).Insert
> Next i
> End Sub
>
>
>
> On Fri, Feb 25, 2011 at 7:21 PM, Jason Henke <jsin...@gmail.com> wrote:
> > Hello,
>
> > In the attached file I have provided an example of what I am trying to
> > accomplish via macros.
>
> > I import a report into excel that changes each time it's ran. I'm trying to
> > put a space after each 'group' is ran. As an example we have locations set
> > up as
> > A-A-0
> > A-A-1 ect..to A-C-3
>
> > B-A-0 to B-F-3
>
> > more data in sheet to show. I would like to insert a row after each area.
> > So A-A-0 to A-C-3 would be one group. B-A-0 - B-F-3 is another. Not all
> > these locations will show when the report runs. If needed I can provide a
> > list of every location that I need this data to sort by (and I can provide
> > groups).
>
> > Once the rows are inserted I will be running a macro to place page breaks
> > after each blank row.. this I already have though.
>
> > Regards,
> > Jason
>
> > --
>
> > ---------------------------------------------------------------------------­-------
> > Some important links for excel users:
> > 1. Follow us on TWITTER for tips tricks and links :
> >http://twitter.com/exceldailytip
> > 2. Join our LinkedIN group @http://www.linkedin.com/groups?gid=1871310
> > 3. Excel tutorials athttp://www.excel-macros.blogspot.com
> > 4. Learn VBA Macros athttp://www.quickvba.blogspot.com
> > 5. Excel Tips and Tricks athttp://exceldailytip.blogspot.com
>
> > To post to this group, send email to excel-macros@googlegroups.com
>
> > <><><><><><><><><><><><><><><><><><><><><><>
> > Like our page on facebook , Just follow below link
> >http://www.facebook.com/discussexcel
>
>
>
>  insert_rows_Solutionm.xls
> 62KViewDownload- Hide quoted text -
>
> - Show quoted text -

-- 
----------------------------------------------------------------------------------
Some important links for excel users:
1. Follow us on TWITTER for tips tricks and links : 
http://twitter.com/exceldailytip
2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310
3. Excel tutorials at http://www.excel-macros.blogspot.com
4. Learn VBA Macros at http://www.quickvba.blogspot.com
5. Excel Tips and Tricks at http://exceldailytip.blogspot.com
 
To post to this group, send email to excel-macros@googlegroups.com

<><><><><><><><><><><><><><><><><><><><><><>
Like our page on facebook , Just follow below link
http://www.facebook.com/discussexcel

Reply via email to