is output running on file?, keep file locked ?

Jeff Harrison jeffaharrison at yahoo.com
Mon Apr 18 19:13:15 PDT 2005


--- Mike Fedko <filepro at adelphia.net> wrote:
> windows 2000 advanced server
> filepro 5.0.09
> 
> 
> I have a visual basic ordering program that my
> customers use. The order prog has a transmit button
> that FTP's an order.txt file to an orders dir on my
> website. On my end, I have another FPT program that
> downloads the order.txt file to a folder called
> orders on my computer. I am using filepro with sleep
> to scan the orders dir every few seconds. If a file
> called "order.txt" exists, I import it into Filepro,
> generate an invoice, print a pick sheet, and send a
> confirmation back to the website. The visual basic
> order program will get the response if all works
> well.
> 
> I want to make this process bulletproof, if at all
> possible. The biggest problem I see is, what if
> someone in my office is printing at the same time
> this automated process tries to print. The automated
> process is going to sit there saying "filepro error
> occurred, request output running on file, etc..."
> 
> What I would really like to do is, as soon as I see
> the file in the orders dir, check if output file is
> locked. If it is not locked, then lock it. NOW
> import file in, generate invoice, unlock and print
> pick sheet, respond back successful.  
> 
> I guess the whole point is to avoid hitting the
> "filepro error occurred, request output running on
> file" I don't know the best way to do it. Has anyone
> done similar stuff.
> 
> Any help will be greatly appreciated
> 
> Thank You, 
> Mike Fedko
> 
>   > _______________________________________________

So you are saying that you are using dreport or
rreport to import the file and you are worried that
someone will try to go into Inquire/Update/Add on this
file at the same time?  If that is the case you can
simply use the -u flag on the dreport/rreport process
to avoid this error.

Alternately, you could use dclerk/rclerk with @menu
processing to import the file, and thereby avoid
request output altogether.

Jeff Harrison
jeffaharrison at yahoo.com

Author of JHExport and JHImport.  The easiest and
fastest way to generate code for filePro exports and
imports.




		
__________________________________ 
Do you Yahoo!? 
Plan great trips with Yahoo! Travel: Now over 17,000 guides!
http://travel.yahoo.com/p-travelguide


More information about the Filepro-list mailing list