Tom's Hardware > Forum > Windows XP > Configuration & Customize > Environment variable set where?

Environment variable set where?

Forum Windows XP : Configuration & Customize - Environment variable set where?

Tom's Hardware: Over 1.4 million members in 6 different countries available to answer all your high-tech questions. Sign up now! Its free!
Word :    Username :           
 

Archived from groups: microsoft.public.windowsxp.configuration_manage (More info?)

 

Hi,

I have an application that uses the environment variable ClientName to store
some information. It looks like this env. variable is set in the registry
in the hkcu hive. It is set for console, is this some sort of default and
can I change it? Do I have to change it here or is there a control panel
somewhere that handles this setting? I first looked in the System control
panel, under Environment Variables but didn't see it there at all.

I want to set this to the machine name cause I have a number of identical
systems and they are currently all set the same, I'd like them unique.

Any suggestions?

Thanks in advance,
Linn

Sponsored Links
Register or log in to remove.

Archived from groups: microsoft.public.windowsxp.configuration_manage (More info?)

 

"Linn Kubler" wrote:
| Hi,
|
| I have an application that uses the environment variable ClientName to
store
| some information. It looks like this env. variable is set in the registry
| in the hkcu hive.
* Where are you getting this?

It is set for console, is this some sort of default and
| can I change it?
* And this?

Do I have to change it here or is there a control panel
| somewhere that handles this setting? I first looked in the System control
| panel, under Environment Variables but didn't see it there at all.
* From a command prompt;
set
will display the system and user environment variables.


| I want to set this to the machine name cause I have a number of identical
| systems and they are currently all set the same, I'd like them unique.
* You can ADD the variable to Control Panel|System|Advanced|Environment
Variables as a system or user variable depending on your needs.

--
Regards,

Dave Patrick ....Please no email replies - reply in newsgroup.
Microsoft Certified Professional
Microsoft MVP [Windows]
http://www.microsoft.com/protect

Reply to Anonymous

Archived from groups: microsoft.public.windowsxp.configuration_manage (More info?)

 

On Fri, 15 Jul 2005 17:16:18 -0500, "Linn Kubler"

>I have an application that uses the environment variable ClientName to store
>some information. It looks like this env. variable is set in the registry
>in the hkcu hive. It is set for console, is this some sort of default and
>can I change it? Do I have to change it here or is there a control panel
>somewhere that handles this setting? I first looked in the System control
>panel, under Environment Variables but didn't see it there at all.

>I want to set this to the machine name cause I have a number of identical
>systems and they are currently all set the same, I'd like them unique.

Newly-started sessions take their variables from the following
registry keys, so that setting these before any sessions have started
will pass variables to the environment of these sessions:

HKLM\SYSTEM\CurrentControlSet\...\Environment
HKCU\Environment
HKCU\Volatile Environment

The HKEY_CURRENT_USER settings override (in the case of Path, append)
the values set in HKEY_LOCAL_SYSTEM. As the name suggests, the
Volatile Environment does not persist after restarting Windows.

If you set values in these keys programatically, e.g. my merging in a
..REG file or using Reg from a batch file, then the changes do not
appear until the next Windows session (or ever, in the case of
Volatile). So you may need MS's SetX.exe from the SP2 Support
subtree, or a free third-party tool called SetEnv.exe

SetEnv has easier syntax than SetX.exe, plus it supports the Volatile
Environment, which SetX.exe does not.

Both these tools will cause changes to be immediately available to
sessions started after the changes are made. Any existing sessions
will more likely ignore the changes, unless they specifically check to
see whether the environment has changed.



>------------------------ ---- --- -- - - - -
Forget http://cquirke.blogspot.com and check out a
better one at http://topicdrift.blogspot.com instead!
>------------------------ ---- --- -- - - - -

Reply to Anonymous

Archived from groups: microsoft.public.windowsxp.configuration_manage (More info?)

 

Thanks for the information. My problem isn't how to set the environment
variable but rather simply identify where the env. is being set. Once I
locate that I can try to figure out how to set it the way I want.

Thanks,
Linn

"cquirke (MVP Windows shell/user)" <cquirkenews@nospam.mvps.org> wrote in
message news:25umd110ihhknn7r6sp7185tuticqkn46h@4ax.com...
> On Fri, 15 Jul 2005 17:16:18 -0500, "Linn Kubler"
>
> >I have an application that uses the environment variable ClientName to
store
> >some information. It looks like this env. variable is set in the
registry
> >in the hkcu hive. It is set for console, is this some sort of default
and
> >can I change it? Do I have to change it here or is there a control panel
> >somewhere that handles this setting? I first looked in the System
control
> >panel, under Environment Variables but didn't see it there at all.
>
> >I want to set this to the machine name cause I have a number of identical
> >systems and they are currently all set the same, I'd like them unique.
>
> Newly-started sessions take their variables from the following
> registry keys, so that setting these before any sessions have started
> will pass variables to the environment of these sessions:
>
> HKLM\SYSTEM\CurrentControlSet\...\Environment
> HKCU\Environment
> HKCU\Volatile Environment
>
> The HKEY_CURRENT_USER settings override (in the case of Path, append)
> the values set in HKEY_LOCAL_SYSTEM. As the name suggests, the
> Volatile Environment does not persist after restarting Windows.
>
> If you set values in these keys programatically, e.g. my merging in a
> .REG file or using Reg from a batch file, then the changes do not
> appear until the next Windows session (or ever, in the case of
> Volatile). So you may need MS's SetX.exe from the SP2 Support
> subtree, or a free third-party tool called SetEnv.exe
>
> SetEnv has easier syntax than SetX.exe, plus it supports the Volatile
> Environment, which SetX.exe does not.
>
> Both these tools will cause changes to be immediately available to
> sessions started after the changes are made. Any existing sessions
> will more likely ignore the changes, unless they specifically check to
> see whether the environment has changed.
>
>
>
> >------------------------ ---- --- -- - - - -
> Forget http://cquirke.blogspot.com and check out a
> better one at http://topicdrift.blogspot.com instead!
> >------------------------ ---- --- -- - - - -

Reply to Anonymous
Tom's Hardware > Forum > Windows XP > Configuration & Customize > Environment variable set where?
Go to:

There are 1300 identified and unidentified users. To see the list of identified users, Click here.

Please mind

You are about to answer a thread that has been inactive for more than 6 months.
If you still wish to proceed, please ensure that your posting is original and does not duplicate or overlap any prior responses to this thread.

Add a reply Cancel
Sponsored links
  • Ask the community now
  • Publish
Ad
They won a badge
Join us in greeting them