BIGTONE559
Active Member
- Joined
- Apr 20, 2011
- Messages
- 336
I'm seem to be having an issue with syntax.
I normally use the following:
I'm trying to do the same for DataValidation however, i must have something wrong because it keeps throwing an error 1004
Help Appreciated
I normally use the following:
Code:
Sub COPYFORMAT()
Application.EnableEvents = False
Sheets(3).Range("A11:O45").Copy
Sheets(4).Range("A11:O45").PasteSpecial xlFormats
Sheets(5).Range("A11:O45").PasteSpecial xlFormats
Sheets(6).Range("A11:O45").PasteSpecial xlFormats
Sheets(7).Range("A11:O45").PasteSpecial xlFormats
Sheets(8).Range("A11:O45").PasteSpecial xlFormats
Sheets(9).Range("A11:O45").PasteSpecial xlFormats
Sheets(10).Range("A11:O45").PasteSpecial xlFormats
Sheets(11).Range("A11:O45").PasteSpecial xlFormats
Sheets(12).Range("A11:O45").PasteSpecial xlFormats
Sheets(13).Range("A11:O45").PasteSpecial xlFormats
Application.EnableEvents = True
End Sub
I'm trying to do the same for DataValidation however, i must have something wrong because it keeps throwing an error 1004
Code:
Sub Datavalcopy()
Application.EnableEvents = False
Sheets(3).Range("A11:A45").Copy
Sheets(4).Range("A11:A45").PasteSpecial xlDataValidation
Sheets(5).Range("A11:A45").PasteSpecial xlDataValidation
Sheets(6).Range("A11:A45").PasteSpecial xlDataValidation
Sheets(7).Range("A11:A45").PasteSpecial xlDataValidation
Sheets(8).Range("A11:A45").PasteSpecial xlDataValidation
Sheets(9).Range("A11:A45").PasteSpecial xlDataValidation
Sheets(10).Range("A11:A45").PasteSpecial xlDataValidation
Sheets(11).Range("A11:A45").PasteSpecial xlDataValidation
Sheets(12).Range("A11:A45").PasteSpecial xlDataValidation
Sheets(13).Range("A11:A45").PasteSpecial xlDataValidation
Application.EnableEvents = True
End Sub
Help Appreciated