setting default directory using 'answer file'

Rob Cozens rcozens at pon.net
Mon Jan 9 12:08:11 EST 2006


Hi Jason,

>>I want to use a 'answer file' open command but I want it to open up a
>>directory named "images" which will be in the same directory as the
>>application.

 From the app:

set the itemDelimiter to "/"
get the effective fileName of me
put "images" into item -1 of it
put "/" after it
answer file "Choose a file:" with it

Note: For this to work for compiled Mac OSX standalones, the images 
folder must reside _inside_ the application bundle, not in the folder 
containing the application bundle.

Rob Cozens CCW
Serendipity Software Company

"And I, which was two fooles, do so grow three;
  Who are a little wise, the best fooles bee."

  from "The Triple Foole" by John Donne (1572-1631)





More information about the use-livecode mailing list