![]() |
#3
|
|||
|
|||
![]()
Nosparks, Highlighted DestSh is now coming up as Invalid qualifier.
Originally I had "Dim DestSh As Worksheet" rather than "string"? Sub CopyDataWithoutHeaders() Dim sh As Worksheet Dim DestSh As String Dim Last As Long Dim shLast As Long Dim CopyRng As Range Dim StartRow As Long With Application .ScreenUpdating = False .EnableEvents = False End With ' Clear the summary sheet. DestSh = "RDBMergeSheet" With Sheet26 '<~~~~ the sheet's code name .UsedRange.ClearContents .Name = DestSh End With ' Fill in the start row. StartRow = 7 ' Loop through all worksheets and copy the data to the ' summary worksheet. For Each sh In ActiveWorkbook.Worksheets If sh.Name <> DestSh.Name Then |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Run Time Error '91': Object variable or With block variable not set using Catalogue Mailmerge | Berryblue | Mail Merge | 1 | 11-13-2014 05:36 PM |
![]() |
JUST ME | Word VBA | 4 | 03-25-2014 06:56 AM |
![]() |
MJP143 | Excel | 1 | 02-11-2013 05:07 AM |
Variable to rename a tab in a worksheet via VBA | Chayes | Excel Programming | 5 | 08-07-2012 02:03 AM |
![]() |
tinfanide | Excel Programming | 2 | 06-10-2012 10:17 AM |