Error "52" bad file number or file name problem

R

Ryan Stechschulte

I am having trouble with an application which calles Excel
with the Shell command.

"C:\Program Files\Microsoft Office 2000
\Office\Excel.Exe" "MyFile.csv" "File2.xls" /e

The second file build a new workbook using some macros. It
opens excel and runs fine on Machine A and not on Machine
B. Machine A is the dev box and on both A and B the Excel
versions match, the dll's match for ODBC, OLE DB, and
Excel. If I past the string above into the run box it will
run fine, but when called from the program on Machine B it
gives the excel error 52. Any thoughts?
 
J

jaf

Hi Ryan,
Your not passing a path with the filenames. Are the paths to the files the
same on both machines?
 
R

Ryan Stechschulte

Sorry forgot to mention that I am putting a path with the
files myFile and File2. They are the same on both machines.
 

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