Excel VBA issue

  • Thread starter Thread starter G
  • Start date Start date
G

G

Hi,

I have written a VBA application which reads data from DB
and creates an exce file with the data. This is working
fine on one computer, but when I try to run this VBA app
on a different computer, it is not creating the excel
file. Curious to know if Excel is working on that 2nd
computer, I launched excel manually and to my surprise
Excel not only opened a blank file but it also opened
another Excel file with the data I was saving from VBA.
When I am closing that file it asks me if I want to save
the information.
My question is why is not able to save the file on to the
hard disk, if the same VBA works on my system, is there
any thing wrong on the 2nd computer. Please let me know if
there is any thing I need to do to make it work. 2nd
computer has Excel 2000 installed.

TIA
-G
 
Insert the line;

Excel.Application.Visible = True

After the code creates the file. It’s there. You just can’t see it.
Piku
 
Thanks Pikus,

But I don't want to launch excel, I just want to create
the file on the hard drive. It works fine on 1st computer,
creates excel file, but on 2nd, it does not create the
excel file.

Thanks
-G
 
What I mean is that your problem is not that the file is not bein
created. If you add that line you'll be able to see that it doe
indeed exist. You should look more towards how it is being saved t
find the problem. - Piku
 
Back
Top