[futurebasic] Re: [FB] Controlling FILES$ for opening and saving

Message: < previous - next > : Reply : Subscribe : Cleanse
Home   : January 2005 : Group Archive : Group : All Groups

From: John McKernon <misc@...>
Date: Wed, 05 Jan 2005 22:00:08 -0500
> I am getting this to work.   Unfortunately, I did it before Jamin's
> hack got in, so it is a little different.   But I am controlling the
> get file and save file's starting point.   I am saving a filespec as an
> alias and controlling access to not only the local drive but to
> servers...even across a WAN.   Be glad to look at what you have and see
> if we can't get this going.

What I'm doing is very simple: I make an FSSpec that contains the ParentID
of the folder I want the file to go in, the Volume reference, and the
default filename. I then use FILES$(_FSSpecSave,"Where do you want to put
the file?",Filename$,FSSpecRecord). Where FILES$ takes me is fairly random,
but it's very often the desktop.

If I skip the FILES$() dialog entirely and simply save the file using the
FSSpecRecord I made, the file goes right where I want it. Unfortunately,
that doesn't give the user an opportunity to name it or put it somewhere
else if they want to. The point here is to have a default place for the
file, so the user doesn't have to go hunting for the appropriate folder.

I seem to recall that Jamin's hack worked a long time ago, but it hasn't
worked lately (maybe since OSX?), and I noticed that the OSX documentation
recommends using NavCreatePutFileDialog, etc. instead of NavPutFile that
FILES$() is currently using. I don't know enough about these things to know
if that's part of the problem or not.

Any suggestions will, as always, be greatly appreciated.
          
-- John McKernon