Welcome!

By registering with us, you'll be able to discuss, share and private message with other members of our community.

SignUp Now!

How to? Global variable set /v

Oct
362
2
Hello -- Is this by design .... I issued the the command

set /v foo=%_date %_time

it a tabbed tcc window running under tcmd

I then created a 2nd window and the variable "foo" is not defined -- is this by defined ?

create "foo" outside of tcmd, each created tab'ed window had "foo" defined

thanks

fpe
 
I think it is by design. Your second tab got its environment from its parent, TCMD, and TCMD got its environment before you "set /v foo ...".
 
I think it is by design. Your second tab got its environment from its parent, TCMD, and TCMD got its environment before you "set /v foo ...".
Maybe I was wrong about that. Your experiment works here. Start TCMD ... in the one (default) tab, "SET /V zzz=xxx" ... start a new tab ... and I find that zzz=xxx. I think you need to ...

Options ... TCMD ... Advanced ... check "Update Environment on System Change"
 
TCC sessions get their environment from their parent. If TCC is in a tab window, the parent is TCMD, not the Windows shell, so updating variables in the shell won't have any effect until TCMD is restarted.

If you go to the Options menu in TCMD and select "Configure Take Command / Advanced", you can select the "Update Environment on System Change" option to have TCMD's environment automatically updated.
 
Back
Top
[FOX] Ultimate Translator
Translate