Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
OLE with Excel
Message
From
23/07/2002 11:10:22
Mike Smith
Doncaster Office Services
Oakville, Ontario, Canada
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
OLE with Excel
Miscellaneous
Thread ID:
00681685
Message ID:
00681685
Views:
50
I know Tamar Ganor has written a book on this and I will be ordering it when I get back to my office. Currently I am out of town and all I have is the VFP Help System.

I am developing an application that uses OLE to send out VFP data to a MS Excel Spreadsheet.

I have it working quite well and I am really heppy with it but I am having a problem with the file management.

i.e. To get a clean and proper copy of the spread sheet I start with the line of code below:

COPY FILE PM1.XLS TO POSTEDMARKS1.XLS && THIS CLEARS OUT THE OLD COPY

Then I start the transfer code:

OLEAPP = CREATEOBJECT("Excel.Application")

My problem is if the operator has the file POSTEDMARKS1.XLS open in MS Excel, then the COPY FILE code fails.

I am trying to find a way of determining if the POSTEDMARKS1.XLS is already open and if it is, I would bypass the COPY FILE code.

If someone can help me with this it would be great.

Mike Smith
Next
Reply
Map
View

Click here to load this message in the networking platform