Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to tell when printing to file is finished?
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
How to tell when printing to file is finished?
Miscellaneous
Thread ID:
00847854
Message ID:
00847854
Views:
61
I have an app that monitors a specific directory. My users print documents to file into that directory (.pcl files). When my program notices a .pcl file in the dir, it tries to convert the .pcl to .pdf.

My problem is that some of the .pcl files are very large and take a while to create. My program notices the file and begins to try to convert even though the printing has not yet finished.

I've tried to check for a file still being created by doing the following:
lhFile = fopen(lcFileName,10)
if lhFile = -1
   Loop
else
   ... do the conversion
endif
However, for some reason this doesn't seem to be catching the fact the the file is still being created.

Any more ideas? Thanks for whatever help you can offer!
Next
Reply
Map
View

Click here to load this message in the networking platform