Solved

modify Environment variable

Posted on 2012-03-15
6
227 Views
Last Modified: 2012-08-13
HI,

I want to modify the "Path" environment variable in system using C++.
I have a reference of Oracle in the "path" variable which I want to remove as I am uninstalling oracle.
Thanks for the help.

Srinivas
0
Comment
Question by:SPATNAIK
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
6 Comments
 
LVL 44

Expert Comment

by:Darr247
ID: 37726941
Environment Variables are in sysdm.cpl on the Advanced tab.

Start->Run, sysdm.cpl [Enter]

In the bottom section, click on Path, then the Edit button.

You can view current environment variables by opening a command window and running
SET
by itself.
0
 

Author Comment

by:SPATNAIK
ID: 37727956
Hi,
Thanks for the response.
Actually I want to modify the Environment variable from my C++ program.

Thanks,
Srinivas
0
 
LVL 44

Accepted Solution

by:
Darr247 earned 500 total points
ID: 37727998
Oh...  the path is also stored in the registry at
HKLM\SYSTEM\CurrentControlSet\Control\Session Manager\Environment\Path
0
 

Author Comment

by:SPATNAIK
ID: 37728248
If there is any Windows API to do this it would have been nice.
Anyways Thanks for the response. I will update the registry programatically and check the results.
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Ready to improve network connectivity? Watch this webinar to learn how SD-WANs and a one-click instant connect tool can boost provisions, deployment, and management of your cloud connection.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Ok I have been working on this for some time having learned and gained certification in XenDesktop 4 along came version 5 which was released last month. Since then I have been working to deploy XenDesktop 5 in a small environment with only 2 virt…
We have adopted the strategy to use Computers in Student Labs as the bulletin boards. The same target can be achieved by using a Login Notice feature in Group policy but it’s not as attractive as graphical wallpapers with message which grabs the att…
Two types of users will appreciate AOMEI Backupper Pro: 1 - Those with PCIe drives (and haven't found cloning software that works on them). 2 - Those who want a fast clone of their boot drive (no re-boots needed) and it can clone your drive wh…
If you're a developer or IT admin, you’re probably tasked with managing multiple websites, servers, applications, and levels of security on a daily basis. While this can be extremely time consuming, it can also be frustrating when systems aren't wor…

729 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question