for the first time in many years of maxing, I'm attempting to put
together a proper save/load system for the patch I'm building. I've
been looking through the help files and manual, but it's not making
any sense to me.
My patch creates audio buffers with associated coll files (the coll
contains a list of audio segments in the buffer~, created with
record~ in append mode).
I want to save both buffer and coll with similar names - ie the user
enters a filename using textedit, and then an aiff file and a coll
text file are saved with the same name (but obviously different file
types). and then I'm going to want to do the same in reverse (ie load
the two related files).
I used to do this as two separate operations, but that's untidy,
which is why I want to do it as a single (as far as the user is
concerned) operation. I'm also trying to avoid having the user open a
save dialog as that does require the 2 separate save dialogs - one
for the buffer and another for the coll.
So I want the user to enter a filename, click on a button, and then
everything else happen in the background.
I've figured out how to use textedit instead of dialog, so that bit's
done. And I've managed to get coll to save using [prepend write]
following the file name. The thing I'm currently having problems with
is setting the file path - I want to save the files in a specific
folder inside the patcher folder. I need to tell both coll and
buffer~ to use this path for these specific save and load operations.
Can anyone give me any pointers as to how to go about doing this
(asuuming that it's possible!)