When one adds a new entry to the File Preferences list, you give a name and a path.
Is there a way to retrieve a specific path programatically, given the name?
not sure what you mean, [absolutepath] gives you the path of a file in searchpath.
If you click on File Preferences, you can add new folders to the search path. Those folders are given names. I would like to be able to use a name to find the appropriate search path.
However, I just read the documentation on File Preferences and it says
"You can give the entry you add to the search path a name in the Name column. However, this name has no functional importance and is only for your future reference."
so I am SOL (sigh)
I’ll have to see if I can figure out how to get the value of an environment variable instead.
didn’t notice there’s a name column. the env variables you’ll only get via external AFAIK. O.
I have solved this problem by putting a Max object that returns the path where it is located into each folder on my search path. The name of the object is the same as that defined in the File Preferences (just for convenience).
The File Prefs should be stored in a file somewhere, though I just looked and couldn’t find it. If so, you might be able to load it into [text] and parse it somehow.
Not a bad idea. However, it would be nice if Cycling74 would add an object to a future update that can retrieve the path given the name.
Log in to reply
SUBSCRIBE TO OUR NEWSLETTER
C74 RSS Feed | © Copyright Cycling '74 | Terms & Conditions