I have a report done for me but the sheet names flip flop between "Migrated" or "Sheet 1" and "Non-Migrated" or "Sheet 2". So my macro breaks.
How do I set worksheet to have either name. I don't know if I have to do an array and if I do, how to use that other than just declaring the array.
![]()
Sub ED4NotepadFormat() 'On Error Resume Next Application.ScreenUpdating = False Application.DisplayAlerts = False Dim sht As Worksheet Dim objListObj As ListObject 'Migrated - Sheet 1 Set sht = ActiveWorkbook.Worksheets("Non-Migrated") '''or sheet 1 'Non-Migrated - Sheet 2 Set wrksht = ActiveWorkbook.Worksheets("Migrated") '''or sheet 2 Dim lastrow As String Dim ws As Worksheet
Bookmarks