Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Can anyone tell me why this code is not working? It always gives me a VB
error when it gets to: Range.Select = ("A2:I27") All I want to do is copy that range from one excel file to another file. Private Sub CommandButton1_Click() 'phil ChDir "\\eeroch1nas02\home\CapursoP\Stats\temp" Workbooks.Open Filename:= _ "\\eeroch1nas02\home\CapursoP\Stats\temp\Agent work share.xls" Windows("Agent work share.xls").Activate Sheets("Phil").Select Range.Select = ("A2:I27") Selection.Copy Windows("Agent work share totals template - Version 2.xls").Activate Sheets("Phil").Select Range("A2").Select ActiveSheet.Paste Range("J2").Select Windows("Agent work share.xls").Activate Application.CutCopyMode = False ActiveWindow.Close End Sub Thanks, Phil |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Macro not working correctly | Excel Discussion (Misc queries) | |||
Formulas not working correctly | Excel Worksheet Functions | |||
SUM formula not working correctly | Excel Worksheet Functions | |||
Autofilter not working correctly... | Excel Discussion (Misc queries) | |||
Column find code not working correctly | Excel Programming |