Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Creating Excel from within VB6

Status
Not open for further replies.

AOLBoy

IS-IT--Management
May 7, 2002
68
0
0
GB
I have programmatically created an Excel spreadsheet from my VB6 program. I then go on to update the Excel spreadsheet by creating new sheets and adding data into those sheets.

My problem is that is an inconsistency in its performance - in some cases the process works fine, but at other times it fails because the create hasn't worked. If I run in debug it always works. I suspect that the program is trying to access the spreadsheet before the create operation is complete. Can this happen?, has anybody experienced this before?, is their any sort of wait operation that can be applied?

Any help would be much appreciated.
 
Check that you are closing down properly and destroying the objects. When it starts failing go to the task manager and see if you have multiple versions of Excel running.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top