Hey everyone, I'm hoping for some help with an issue I am having. What I am trying to do is copy multiple ranges not next to eachother and paste them into a different tab in the workbook. Here is the code that is having the issue:
Sub Sup_1() Dim SETT As String Dim pwd As String Dim TABNM As String pwd = "test" TABNM = Sheets("Support").Range("G3).Value SETT = Sheets("Support").Range("H3).Value Sheets(TABNM).Select ActiveSheet.Unprotect Password:=pwd Sheets(TABNM).Range("B21:M21,B34:N34,B47:N47,B57:N57").Select Sheets(TABNM).Range("B57").Activate Selection.Copy Sheets(SETT).Select Sheets(SETT).Range("B4").Select Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _ :=False, Transpose:=False End sub
When it gets to the Selection.Copy part it errors out as Run-Time error 1004 Command cannot be used on multiple selections. What I don't understand is I can use the record macro button, do the exact same copy and paste exercise in the same file without getting an error about the multiple selections. Does anyone know why I am getting this and if there is a way around it? Any help would be greatly appreciated, thanks!
Bookmarks