Environment Variables get lost?

J

Joe HM

Hello -

I am running Windows XP SP1 and several times a day an environment
variable I set through My Computer > Properties > Advanced >
Environment Variables > User variables for USER gets lost. I notice
that because I have some shortcuts on my desktop where the path to the
executable as well as the path to the icon contain a %X% where X is the
environment variable in question. The icon turns into the default
Windows icon since XP cannot find the path anymore.

Interestingly, if I open the environment variable to edit (Edit Button)
and then close the window with the OK Button, it seems to be fine. I
just hit F5 on my desktop and the icon for the shortcut is visible
again. The shortcut will then also work again.

Any ideas? I thought maybe with SP2 this could be resolved but I was
told by our IT department to not install SP2. Is there a HotFix for
that?

Thanks,
Joachim
 
D

David H. Lipman

From: "Joe HM" <[email protected]>

| Hello -
|
| I am running Windows XP SP1 and several times a day an environment
| variable I set through My Computer > Properties > Advanced >
| Environment Variables > User variables for USER gets lost. I notice
| that because I have some shortcuts on my desktop where the path to the
| executable as well as the path to the icon contain a %X% where X is the
| environment variable in question. The icon turns into the default
| Windows icon since XP cannot find the path anymore.
|
| Interestingly, if I open the environment variable to edit (Edit Button)
| and then close the window with the OK Button, it seems to be fine. I
| just hit F5 on my desktop and the icon for the shortcut is visible
| again. The shortcut will then also work again.
|
| Any ideas? I thought maybe with SP2 this could be resolved but I was
| told by our IT department to not install SP2. Is there a HotFix for
| that?
|
| Thanks,
| Joachim

What exactly is the environmental variable that you are setting ?

What exactly is the properties of the command line of the LNK (shortcut) using this
environmental variable ?
 
N

Nepatsfan

Joe said:
Hello -

I am running Windows XP SP1 and several times a day an
environment variable I set through My Computer > Properties
gets lost. I notice that because I have some shortcuts on
my desktop where the path to the executable as well as the
path to the icon contain a %X% where X is the environment
variable in question. The icon turns into the default
Windows icon since XP cannot find the path anymore.

Interestingly, if I open the environment variable to edit
(Edit Button) and then close the window with the OK Button,
it seems to be fine. I just hit F5 on my desktop and the
icon for the shortcut is visible again. The shortcut will
then also work again.

Any ideas? I thought maybe with SP2 this could be resolved
but I was told by our IT department to not install SP2. Is
there a HotFix for that?

Thanks,
Joachim

I'm no expert on domains but you might want to check with your
IT department. It's very possible that they have a group policy
in place that restores certain registry settings such as
environmental variables. Throughout the day this policy may be
refreshed which could cause the type of behavior you're
experiencing.

Good luck

Nepatsfan
 
J

Joe HM

Hello -

I have an environment variable called FMW and currently it is set to
"21-01". In the shortcut I have a path like "C:\Program
Files\Company\Application\%FW%\bin\Application.exe".

Under Windows 2000 this worked fine and it actually works fine for all
other XP users in my company as well. The path to the icon is set
similarily.

Thanks,
Joe
 
J

Joe HM

Hello -

I will check with them but I never had the problem with Windows 2000
and other user of XP do not have the problem either.

Really strange ...

Thanks,
Joe
 
D

David H. Lipman

From: "Joe HM" <[email protected]>

| Hello -
|
| I have an environment variable called FMW and currently it is set to
| "21-01". In the shortcut I have a path like "C:\Program
| Files\Company\Application\%FW%\bin\Application.exe".
|
| Under Windows 2000 this worked fine and it actually works fine for all
| other XP users in my company as well. The path to the icon is set
| similarily.
|
| Thanks,
| Joe

OK Thanx.

Thats a simple variable assignment and there should be no reason why it won't "stick". Have
you tried making it a system variables vs. user variable ?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top