Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I need this sub to allow me to specify the path to the
file I want to open here so that no matter what the current path is, it will find this file. It works in cases where this path is already the current path, but the open file fails if another folder is the active path. But this sub refuses to do what I want it to do. It just keeps insisting an object is required on the line where I set path = "D:\.... If I remove the " ", then it highlights the "/" and says something about expects a line number. I wish this thing would learn to speak English for a change. Sub Import() Dim cRows As Long Dim path As String Set path = "D:\myfiles\data\ttax\" Sheets("Import").Select Application.Goto Reference:=("Importarea") Selection.CurrentRegion.Clear Range("A1").Select Workbooks.Open Filename:="path" & "LUSE.WK1" Thanks, Bruce |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Excel variable for path | New Users to Excel | |||
variable path | Links and Linking in Excel | |||
Vlookup using variable path name for range value | Excel Worksheet Functions | |||
hyperlink navigation path path wrong in Excel 2003 | Excel Discussion (Misc queries) | |||
make a vlookup using a variable path | Excel Worksheet Functions |