jph@whuxle.UUCP (05/14/84)
#R:sri-arpa:-59900:whuxle:22700032:000:435 whuxle!jph May 14 12:11:00 1984 It depends in which language the program is being written. BASIC supports `change directory' from which you can then open files in that directory. I have written a routine for the IBM PASCAL compiler which allows me to open files in any directory. It first does a `change directory' and then I can use the PASCAL `assign' statement to open the file. You can do the same thing from any other language by writting the interface routine.
broehl@wateng.UUCP (Bernie Roehl) (05/15/84)
Not sure I understand the question, but here goes: If you are programming in a high-level language environment (e.g. the Basic interpreter or C run-time library) should handle all of this for you, and should have no trouble at all opening files in any arbitrary sub-directory. If you are programming in assembler, the new DOS 2.00 i/o calls can handle full paths, not just ordinary files. If, however, you are using an old version of the language package, or if you are writing in assembler and using the old i/o calls (the ones that explicity "know" about FCB's and suchlike) then you will inevitably run into problems using the hierarchical file system. Simple recommendation: use the new i/o calls, or upgrade to a language system that does. -- -Bernie Roehl (University of Waterloo)
gary@mit-eddie.UUCP (Gary Samad) (05/16/84)
You must have meant that DOS 1.0 only allows you to access files in the current directory (it knows nothing about sub-directories). Under DOS 2.0 try using functions 3D, 3F, etc. You don't even have to use those awful File Control Blocks anymore; you now just need to pass a filename and you get back a 'Handle'. Gary Samad