Derek Bump wrote:
Phil Davis wrote:

You can at least find out what the file permissions are this way:

on mouseUp -- as in a button
  answer folder "Pick the folder containing your file:"
  if it = empty then exit mouseUp
  set the defaultFolder to it
  put the detailed files into tFileList
  filter tFileList with "*Preferences.dat*" -- leaves a single line
  answer item 10 of tFileList -- the file permissions item
end mouseUp

Permissions here can be understood same as on other systems.

Phil

The result of the above script: 666

As I remember from my days of perl scripting, 666 for a file pretty much means that anyone can read/write the file.

666 indicates Satanic influence. If you rebuke it in the name of the diety of your choice the problem should go away.


So with that in mind, how does anyone else write their preferences on a Mac? I'd rather just put the prefs in a custom property, but there's no way to save the data within the standalone other than write it to an external file.

You can put the prefs into a custom prop of a separate stack and save that to the Prefs folder on Mac or the Application Data folder on Win:


   if the platform is "MacOS" then
     get specialFolderPath("Preferences")
   else
     get specialFolderPath(28)
   end if
   put "/fourthworld.com/myPRefs.prf" after it
   create stack "MyPrefsStack"
   set the filename of stack "MyPrefsStack" to it
   save stack "MyPrefsStack"

Where does the "28" come from? In addition to the strings accepted by Rev for specific folders in the specialFolderPath function, both Mac OS and Windows use constants to define others. Ken Ray has generously taken the time to list them all, but alas until he finishes de-framing his site I can't send you the URL to the specific page, only to the page the tips are listed on:

<http://www.sonsothunder.com/index2.htm?http://www.sonsothunder.com/devres/revolution/revolution.htm>

The Tip you're looking for is "file010: 'specialFolderPath' codes", under the section labeled "File/Folder Manipulation".


-- Richard Gaskin Fourth World Media Corporation __________________________________________________ Rev tools and more: http://www.fourthworld.com/rev _______________________________________________ use-revolution mailing list [email protected] http://lists.runrev.com/mailman/listinfo/use-revolution

Reply via email to