View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
JohnUK JohnUK is offline
external usenet poster
 
Posts: 173
Default Windows7 Default path problem

Hi All,
I have just loaded Windows 7 and my workbooks that look for other files in
Documents have now stopped working. I have Documents on a different partition
and have changed the setting in the Windows Documents to look and make the
other Documents the default path, but it still doesnt work.
This is part of the code that did work:

sPath = Application.DefaultFilePath & "\Folder"
Workbooks.Open FileName:= _
"" & sPath & "\File.xls"

I cant change the code to show the actual path (E:Documents for example) as
other people use the same files on different machines.
Any ideas on how I can get around this so that documents is accessed on any
machine
Regards
John