Hi,<?xml:namespace prefix = o ns = "urn:schemas-microsoft-comfficeffice" /><o></o>
I have a macro that is working fine on my local drive but gives "Error 009 - Subscript out of rage" when it is run via another PC accessing via a mapped drive. The macro is being run from inside the file that is on the line that gives the erro message.
<o></o>
Sample code:<o></o>
'**** Open workbooks to transfer temporary data
Workbooks.Open Filename:= _
"G:\CC\Account\2012\Monthly reports\M_Name\Summary\Sup_Name.xls"
Workbooks.Open Filename:= _
"G:\CC\Account\2012\Monthly reports\M_Name\Summary\Temporary_SD.xls"
Windows("Sup_Name.xls").Activate
'Copy and paste the coulmns A,B and C
Sheets("Sheet1").Select
Columns("A:C").Select
Selection.Copy
Windows("Temporary_SD.xls").Activate
Sheets("Temp_RD").Select
Range("A1").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Application.CutCopyMode = False<o></o>
****************************************************
<o></o>
Thanks in advance for your help.<o></o>
<o> </o>
I have a macro that is working fine on my local drive but gives "Error 009 - Subscript out of rage" when it is run via another PC accessing via a mapped drive. The macro is being run from inside the file that is on the line that gives the erro message.
<o></o>
Sample code:<o></o>
'**** Open workbooks to transfer temporary data
Workbooks.Open Filename:= _
"G:\CC\Account\2012\Monthly reports\M_Name\Summary\Sup_Name.xls"
Workbooks.Open Filename:= _
"G:\CC\Account\2012\Monthly reports\M_Name\Summary\Temporary_SD.xls"
Windows("Sup_Name.xls").Activate
'Copy and paste the coulmns A,B and C
Sheets("Sheet1").Select
Columns("A:C").Select
Selection.Copy
Windows("Temporary_SD.xls").Activate
Sheets("Temp_RD").Select
Range("A1").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Application.CutCopyMode = False<o></o>
****************************************************
<o></o>
Thanks in advance for your help.<o></o>
<o> </o>