hello all,
If there is a earlier post on this topic, please refer me to it.
I am writing a VBA macro to copy a selection,
paste it into a different workbook,
then group the newly pasted data,
then hide the data.
Since I am using the mouse to select the cell to insert above each time, it selects only one cell.
I cannot automate the grouping procedure because it groups only one row, the row with the single cell selected.
Anyone have a problem like this before?
The Code is below:
Public Sub CopyContacts() ' ' Macro2 Macro ' Macro recorded 2/4/2011 by ******** ' Dim FinalRow As Integer FinalRow = Range("A65536").End(xlUp).Row Rows("3:" & FinalRow).Copy End Sub Public Sub PasteContactstoCalllist() ' ' Macro1 Macro ' Macro recorded 2/4/2011 by******** Selection.Insert Shift:=xlDown Selection.Rows.Group Application.CutCopyMode = False ActiveSheet.Outline.ShowLevels RowLevels:=1 End Sub
Last edited by Leith Ross; 02-07-2011 at 04:40 PM. Reason: Added Code Tags
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks