Error opening another excel file using vba

G

Guest

I have created a macro that opens another excel file (prices.xls) copies
several cells, closes the file and then pastes data into my original file
(estimate.xls). When prices.xls is located on my hard drive it works fine.
However when I try to put it on a server (where it needs to be in production)
I get a 'run-time error 424'. Here is the code that I use for both.

Workbooks.Open Filename:="c:\Prices.xls"
Wookbooks.Open Filename:="\\server\shared\estimating\prices.xls"

Any guidance would be greatly appreciated.
Thanks
 
S

stevebriz

Rob said:
I have created a macro that opens another excel file (prices.xls) copies
several cells, closes the file and then pastes data into my original file
(estimate.xls). When prices.xls is located on my hard drive it works fine.
However when I try to put it on a server (where it needs to be in production)
I get a 'run-time error 424'. Here is the code that I use for both.

Workbooks.Open Filename:="c:\Prices.xls"
Wookbooks.Open Filename:="\\server\shared\estimating\prices.xls"

Any guidance would be greatly appreciated.
Thanks
here is and idea.
What about mapping a drive to the server and then trying that path..??
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top