
increasing file handels in ms basic v7.1
Quote:
> > I need to increase the number of files I can open in a basic program....
> Just on principle, I disagree. MS-BASICs give you 15 open files, less four
> for the system's use, leaving you 11.
> There is no reason to leave that many files open at one time.
I've done this, and for good reason...
We use Btrieve for our data file handling, and while most of the time, it is
not necessary to have that many files open, there are circumstances where it
is absolutely necessary.
In my example, we use the transaction processing of Btrieve, where you start
a transaction, and perform operations on one or more files, then commit the
entire transaction, or abort if an error occurs anywhere in between which
rolls-back all the changes.
An example of where this is necessary is a "supplier code changer" in our
accounts payable. Since the supplier code is in the supplier master file,
the invoice file, the requisitions file, the budgets file, up to ten
different check registers, etc., the code would need to be changed in ALL
files, and if it fails in any one of them, the whole thing needs to abort.
In order for transaction processing to work, all the files need to be open
at the start.
I've used this interrupt myself to set higher file handles, and it works.
--
Bill Hileman, MCP, CPP, BCIP
Programmer/Analyst, DASI
Yahoo! Club for Certaholics
http://clubs.yahoo.com/clubs/certaholics
Computer Language Comparison
http://www.boneville.net/programming/default.htm