B
Beth
The code below is part of a sub routine to import a text
file, copy it's contents, and paste them into the current
sheet. It works fine, until a user renames the sheet. How
can I modify the Windows(filename).Activate line to
make "filename" relative?
Range(Selection, ActiveCell.SpecialCells
(xlLastCell)).Select
Selection.Copy
===> Windows("Idoc Error Matrix Template.xls").Activate
Application.GoTo Reference:="Replace"
Selection.PasteSpecial Paste:=xlValues,
Operation:=xlNone, SkipBlanks:= _
False, Transpose:=False
file, copy it's contents, and paste them into the current
sheet. It works fine, until a user renames the sheet. How
can I modify the Windows(filename).Activate line to
make "filename" relative?
Range(Selection, ActiveCell.SpecialCells
(xlLastCell)).Select
Selection.Copy
===> Windows("Idoc Error Matrix Template.xls").Activate
Application.GoTo Reference:="Replace"
Selection.PasteSpecial Paste:=xlValues,
Operation:=xlNone, SkipBlanks:= _
False, Transpose:=False