Using variables in Preferences settings

Post here questions and problems related to oXygen frameworks/document types.
jeff_hooker
Posts: 25
Joined: Tue Jun 11, 2019 9:01 pm

Using variables in Preferences settings

Post by jeff_hooker »

Hi folks,
I'd like to be able to give my users a path that they can just copy/paste rather than having to navigate to parts of their computers which are frequently invisible to them, so I want to use a variable like this in the Actions panel of the AI preferences:
${env(LOCALAPPDATA)}\RWS\InfoShare Client\1913712966\Config\OxygenXMLAuthor\AI_JSON
Screenshot 2026-03-19 123905.png
The %LOCALAPPDATA% variable resolves from a command window, and when I create a custom Author variable and define its value as %LOCALAPPDATA% and then use the custom variable in the Preferences interface, it resolves, but so far I can't make the ${env(LOCALAPPDATA)} resolve. What am I doing wrong?
You do not have the required permissions to view the files attached to this post.
Radu
Posts: 9647
Joined: Fri Jul 09, 2004 5:18 pm

Re: Using variables in Preferences settings

Post by Radu »

Hi Jeff,
Strange, I think this should work.
What I do to check if Oxygen can expand an editor variable and to what value it expands it is to use the main menu File->"Open URL" action and in the URL chooser field which appears paste the path something like this:

Code: Select all

file:/${env(LOCALAPPDATA)}\RWS\InfoShare Client\1913712966\Config\OxygenXMLAuthor\AI_JSON/test.xml
Then press OK and Oxygen should attempt to expand the editor variable, create an URL and throw an error that the path to the XML is not found.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
jeff_hooker
Posts: 25
Joined: Tue Jun 11, 2019 9:01 pm

Re: Using variables in Preferences settings

Post by jeff_hooker »

You were correct; it does work. I was missing a part of the path.
Post Reply