Jump to content
Ketarin forum

Variables within variables


AussieJim
 Share

Recommended Posts

Hi,

 

I currently have a global variable {PARoot} which determines the base directory for my installs: {PARoot} = C:\Portable Apps.

 

I also have a global variable {7z} which specifieds the location of 7z.exe: {7z} = C:\Portable Apps\7-Zip\App\App\7-Zip\7z.exe.

 

What I'd really like is to use {PARoot} within {7z}'s definition: {7z} = {PARoot}\7-Zip\App\7-Zip\7z.exe. This way if the root directory changes, I only need to update one variable.

 

I've found one way to do this: Make the {7z} variable local to every application instead of global, and declare it as a textual variable: {7z} = {PARoot}\7-Zip\App\7-Zip\7z.exe. This works fine, except that I have to declare it for every application. I can make it a default, but that still leaves it in 100 different places, if I ever change the location or need to troubleshoot. Is there any way to do this on a global basis?

 

Thanks!

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.