home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!zaphod.mps.ohio-state.edu!uwm.edu!rutgers!ub!acsu.buffalo.edu!ubvmsb.cc.buffalo.edu!v125qmam
- From: v125qmam@ubvmsb.cc.buffalo.edu (Ami R Pflugrad)
- Newsgroups: comp.databases
- Subject: Foxpro: Used() & File In Use
- Message-ID: <C0KAy2.E5M@acsu.buffalo.edu>
- Date: 9 Jan 93 01:05:00 GMT
- Sender: nntp@acsu.buffalo.edu
- Organization: University at Buffalo
- Lines: 29
- News-Software: VAX/VMS VNEWS 1.41
- Nntp-Posting-Host: ubvmsb.cc.buffalo.edu
-
- Hi All!
- Could someone tell me what's going on with my Foxpro Application.
-
- I Have a program that is called by many differnt apps, as a result
- is has to be flexible enough to handle a variety of different
- file views. Therefore I have it programmed to see if the file is
- already open before proceeding. Heres a portion of the code:
-
- IF Used("AcctMast")
- Select AcctMast
- Else
- Select 5
- USE \Foxpro2\Develop\FileMain\Accounts\Acctmast
- EndIF
-
- Now, If the file is already used it will execute the first part
- if not, it should execute the second part.
-
- Here's whats happening....
-
- The File is not already in use when I call the program.
- Therefore the Used() function returns a .F. and the second part of
- the code is executed. But when it encounters the USE \Foxpro2\etc.
- statement, the app blows up with a "FILE IN USE" Error.
-
- Can somone explain why its doing this?
-
- Thanks so Much,
- - Ami :)
-