[futurebasic] Re: [FB] auto loading a file

Message: < previous - next > : Reply : Subscribe : Cleanse
Home   : July 2000 : Group Archive : Group : All Groups

From: David Cottrell <David.Cottrell@...>
Date: Fri, 28 Jul 2000 11:22:28 +1000
>>
>The problem is that the only way I know (currently) how to open files is using FILES$, which asks the user for a file to open/save.
>
>What I want is a kind of preferences file that the application always opens on startup.  It would be in a certain order, and created by my application.
>
>*I decided to change the name of the subject... since I have figured out the PG windows stuff
>________________________________________________________________________

The easiest PG way (which actually doesn't use a "real" preference file (ie one called "myApps preferences" in the preferences folder) is to save what you need to into the Help file created by the PG help filter (you dont actually need to be using the help - but what the heck).

How to do this is on the FAQ page - sorry i don't have the URL handy - someone?

PG will give you the volRefNo, and you determine the filename - hence you can just use OPEN etc to read/write to the file. Just insert the OPEN statement on a _mStart event.

Your getting into real mac programming now - this took me years to start thinking of preference files etc :)

Cheers

David