Hi all,
In an effort to make this code shorter and more efficient i am attempting to rewrite it.
It copies a range from one workbook and pastes into another workbook.
I have several blocks of code like this.
Any suggestions appreciated.
Original:
'Copy and paste site data
Windows("UCPSITE-06.xls").Activate
'The sheet i want to copy from has to be active
Range("BJ5:BJ617").Select
Selection.Copy
Windows("3140UCP2006WithShell.xls").Activate
'The sheet i want to paste to has to be active
Range("I2").Select
ActiveSheet.Paste
'Clears Clipboard
Application.CutCopyMode = False
New:
'Copy and paste site data
Windows("UCPSITE-06.xls").Activate
'in case the sheet is not active call it
Sheets("UCP SITE - Totals").Range("BJ5:BJ617").Copy
Windows("3140UCP2006WithShell.xls").Activate
'in case the sheet is not active call it
Sheets("UCP All Site Rankings").Range("I2").Paste
'Clears Clipboard
Application.CutCopyMode = False
Bookmarks