Click here to Skip to main content
15,923,164 members
Home / Discussions / C#
   

C#

 
GeneralRe: How to return an environment variable? Pin
turbosupramk33-Dec-10 11:27
turbosupramk33-Dec-10 11:27 
AnswerRe: How to return an environment variable? Pin
Ian Shlasko3-Dec-10 10:52
Ian Shlasko3-Dec-10 10:52 
GeneralRe: How to return an environment variable? Pin
turbosupramk33-Dec-10 11:28
turbosupramk33-Dec-10 11:28 
AnswerRe: How to return an environment variable? Pin
PIEBALDconsult3-Dec-10 11:13
mvePIEBALDconsult3-Dec-10 11:13 
GeneralRe: How to return an environment variable? Pin
turbosupramk33-Dec-10 11:29
turbosupramk33-Dec-10 11:29 
AnswerRe: How to return an environment variable? Pin
Dr.Walt Fair, PE3-Dec-10 13:25
professionalDr.Walt Fair, PE3-Dec-10 13:25 
GeneralRe: How to return an environment variable? Pin
turbosupramk33-Dec-10 14:03
turbosupramk33-Dec-10 14:03 
GeneralRe: How to return an environment variable? Pin
Dr.Walt Fair, PE3-Dec-10 14:24
professionalDr.Walt Fair, PE3-Dec-10 14:24 
Yes, that's what I would expect.

The environment variables in your process and the OS and any other process are meant to be totally independent so that total chaos in the OS won't ensue. When you spawn your process (cmd window, etc.) it starts with a copy of the owner's environment variables, but any changes it makes are local to your process (cmd window) and any changes made in another process (a new cmd window or the OS) will not be seen by your process. I think you have confirmed that that's exactly what is happening.

If you need to pass changeable information between processes, environment variables are not the solution. They are meant to be used for more or less static system information.
CQ de W5ALT

Walt Fair, Jr., P. E.
Comport Computing
Specializing in Technical Engineering Software


GeneralRe: How to return an environment variable? Pin
turbosupramk33-Dec-10 18:33
turbosupramk33-Dec-10 18:33 
GeneralRe: How to return an environment variable? Pin
Dr.Walt Fair, PE3-Dec-10 19:52
professionalDr.Walt Fair, PE3-Dec-10 19:52 
QuestionPrevent class member circular initialization? Pin
frattaro3-Dec-10 5:01
frattaro3-Dec-10 5:01 
AnswerRe: Prevent class member circular initialization? Pin
_Erik_3-Dec-10 5:22
_Erik_3-Dec-10 5:22 
AnswerRe: Prevent class member circular initialization? PinPopular
Luc Pattyn3-Dec-10 5:22
sitebuilderLuc Pattyn3-Dec-10 5:22 
GeneralRe: Prevent class member circular initialization? Pin
Dalek Dave3-Dec-10 5:33
professionalDalek Dave3-Dec-10 5:33 
GeneralRe: Prevent class member circular initialization? Pin
frattaro3-Dec-10 5:58
frattaro3-Dec-10 5:58 
GeneralRe: Prevent class member circular initialization? Pin
Luc Pattyn3-Dec-10 7:04
sitebuilderLuc Pattyn3-Dec-10 7:04 
AnswerRe: Prevent class member circular initialization? Pin
PIEBALDconsult4-Dec-10 10:00
mvePIEBALDconsult4-Dec-10 10:00 
QuestionDotNet ThreadPool not meant for long running jobs? Pin
devvvy2-Dec-10 23:51
devvvy2-Dec-10 23:51 
AnswerRe: DotNet ThreadPool not meant for long running jobs? PinPopular
Eddy Vluggen3-Dec-10 0:16
professionalEddy Vluggen3-Dec-10 0:16 
GeneralRe: DotNet ThreadPool not meant for long running jobs? Pin
Dalek Dave3-Dec-10 3:18
professionalDalek Dave3-Dec-10 3:18 
GeneralRe: DotNet ThreadPool not meant for long running jobs? Pin
Eddy Vluggen3-Dec-10 6:48
professionalEddy Vluggen3-Dec-10 6:48 
AnswerRe: DotNet ThreadPool not meant for long running jobs? Pin
Keith Barrow3-Dec-10 0:21
professionalKeith Barrow3-Dec-10 0:21 
GeneralRe: DotNet ThreadPool not meant for long running jobs? Pin
devvvy3-Dec-10 15:20
devvvy3-Dec-10 15:20 
GeneralRe: DotNet ThreadPool not meant for long running jobs? [modified] Pin
Keith Barrow3-Dec-10 21:46
professionalKeith Barrow3-Dec-10 21:46 
GeneralThank you guys Pin
devvvy4-Dec-10 13:54
devvvy4-Dec-10 13:54 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.