Page 1 of 1
Environment variables [SOLVED]
Posted: Mon Jul 24, 2017 8:36 am
by Creave
I want to specify some paths and was wondering why
works but
shows this error:
Where can I find a full list of the environment variables?
Re: Environment variables
Posted: Mon Jul 24, 2017 10:20 am
by Syrinx
Re: Environment variables
Posted: Mon Jul 24, 2017 12:39 pm
by APMichael
Sandboxie uses its own Expandable Variables:
https://www.sandboxie.com/index.php?ExpandableVariables
https://www.sandboxie.com/index.php?ShellFolders
(But you can use the Windows Environment Variables also.)
%Downloads% was never defined but
%{374DE290-123F-4565-9164-39C4925E467B}% should work.
(Check the registry keys mentioned in the second link for an overview.)
Re: Environment variables
Posted: Mon Jul 24, 2017 2:46 pm
by Creave
Yes, I can see them but is it possible to specify more user friendly names?
Re: Environment variables
Posted: Mon Jul 24, 2017 3:47 pm
by Guest10
If you want to specify an OpenFilePath you should open Sandboxie Control's window.
Right-click the sandbox name and then
Sandbox Settings > Resource Access > File Access > Direct Access
If it will apply only to one program (safest choice), click "Add Program" and select that program.
Otherwise, select "Add" and browse to the folder (such as your Downloads folder)
OK your way out.
The setting for the Downloads folder will still show as
%{374DE290-123F-4565-9164-39C4925E467B}%
if you look at the Configure > Edit Configuration window, but otherwise the GUI will show it as "C:\Users\(username)\Downloads" in the Sandbox Settings windows.
Re: Environment variables
Posted: Tue Jul 25, 2017 3:41 am
by Creave
Thanks for the information!
Re: Environment variables
Posted: Tue Jul 25, 2017 5:45 am
by APMichael
Creave wrote: ↑Mon Jul 24, 2017 2:46 pm
Yes, I can see them but is it possible to specify more user friendly names?
Yes, this should be possible. You can add to Sandboxie.ini, for example:
Code: Select all
[GlobalSettings]
Ovr.Downloads=%{374DE290-123F-4565-9164-39C4925E467B}%
(Check the section "Overriding Variables" from the first link.)
Re: Environment variables
Posted: Tue Jul 25, 2017 8:27 am
by Creave
Are variables like %{374DE290-123F-4565-9164-39C4925E467B}% on different systems still valid?
Re: Environment variables
Posted: Tue Jul 25, 2017 8:33 am
by APMichael
Yes, because Microsoft have defined those IDs and names.
Re: Environment variables
Posted: Tue Jul 25, 2017 8:48 am
by Creave
Thank you! I appreciate the help!
Re: Environment variables
Posted: Tue Jul 25, 2017 9:29 am
by APMichael
I'm glad I was able to help.