|
-
September 25th, 2001, 03:41 AM
#1
Enviroment Variables
Hi Everyone,
I have wrote a routine in VB to set the enviroment variables using Windows API's . It is running fine and it is adding evironment variables, but the problems is that it takes me to reboot or log off to make the actual settings takes place..
Is there any code or technique by which i can avoid rebooting or logging off ?
Regards
Nabeel
-
September 25th, 2001, 04:14 AM
#2
Re: Enviroment Variables
The problem here is that every thread takes a local copy of the environment variables at startup and doesn't neccesarily update them until restarted.
Well written programs should refresh their environment variables if you send them a WM_WININICHANGE message though - try sending this to HWND_BROADCAST to see if that has any affect.
HTH,
Duncan
-------------------------------------------------
Ex. Datis: Duncan Jones
Merrion Computing Ltd
http://www.merrioncomputing.com
Check out the new downloads - ImageMap.ocx is the VB control that emulates an HTML image map, EventVB.OCX for adding new events to your VB form and adding System Tray support simply, MCL Hotkey for implemenmting system-wide hotkeys in your application...all with source code included.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|