Click here to Skip to main content
15,902,732 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Copy and Paste in forms Pin
Brian Shifrin10-Nov-03 4:36
Brian Shifrin10-Nov-03 4:36 
Generalequivalence EJB in C# Pin
ljesusde9-Nov-03 23:43
ljesusde9-Nov-03 23:43 
QuestionHow to add an item to the desktop's context menu? Pin
julych9-Nov-03 23:18
julych9-Nov-03 23:18 
AnswerRe: How to add an item to the desktop's context menu? Pin
Antti Keskinen10-Nov-03 8:00
Antti Keskinen10-Nov-03 8:00 
GeneralResizable dialog window without flickering Pin
rrrado9-Nov-03 22:58
rrrado9-Nov-03 22:58 
GeneralRe: Resizable dialog window without flickering Pin
YaronNir10-Nov-03 5:29
YaronNir10-Nov-03 5:29 
GeneralRe: Resizable dialog window without flickering Pin
rrrado10-Nov-03 20:38
rrrado10-Nov-03 20:38 
GeneralChanging environment variabls Pin
Orif9-Nov-03 22:44
Orif9-Nov-03 22:44 
I am trying to change an environment variable from a code.
I have tried the each one of the following:
1. sprintf(szCatiaBase, "CATIA_BASE=%s" , (LPCTSTR)strCatiaBase);
nRet = _putenv(szCatiaBase);

2. sprintf(szSysCall, "set CATIA_BASE=%s", (LPCTSTR)strCatiaBase);
nRet = system(szSysCall);

3. CRegKey rkRegistry;
CString strValueName("CATIA_BASE");
rkRegistry.Open(HKEY_CURRENT_USER, "Environment");
sprintf(szValue, "%s", (LPCTSTR)strCatiaBase);
LONG lRet = rkRegistry.SetValue(HKEY_CURRENT_USER, "Environment", szValue, (LPCTSTR)strValueName);
rkRegistry.Close();


BUT....
None of the above actually changed the environment variable - when I opened the cmd console and tried to see the envonment variable's value thruogh:
> set CATIA_BASE

I got the old value - meaning - the environment has not changed!!!!


Does anybody know how this should be done so the the environment will realy change?????


Thnx
GeneralRe: Changing environment variabls Pin
jmkhael10-Nov-03 0:40
jmkhael10-Nov-03 0:40 
GeneralConverting from ext2 to vfat format Pin
Franz Klein9-Nov-03 22:41
Franz Klein9-Nov-03 22:41 
GeneralRe: Converting from ext2 to vfat format Pin
Brian Shifrin10-Nov-03 4:18
Brian Shifrin10-Nov-03 4:18 
GeneralRe: Converting from ext2 to vfat format Pin
Franz Klein11-Nov-03 9:10
Franz Klein11-Nov-03 9:10 
GeneralDisable. or Enable Network Connections Pin
marcel grunder9-Nov-03 22:36
marcel grunder9-Nov-03 22:36 
GeneralShow Desktop Button Pin
Franz Klein9-Nov-03 22:32
Franz Klein9-Nov-03 22:32 
GeneralRe: Show Desktop Button Pin
jmkhael10-Nov-03 0:38
jmkhael10-Nov-03 0:38 
GeneralRe: Show Desktop Button Pin
Franz Klein11-Nov-03 9:14
Franz Klein11-Nov-03 9:14 
GeneralCToolTipCtrl with CSplitterView Pin
emoiXY - Laurent9-Nov-03 22:28
emoiXY - Laurent9-Nov-03 22:28 
GeneralRe: CToolTipCtrl with CSplitterView Pin
emoiXY - Laurent10-Nov-03 1:15
emoiXY - Laurent10-Nov-03 1:15 
GeneralRe: CToolTipCtrl with CSplitterView Pin
Antti Keskinen10-Nov-03 8:08
Antti Keskinen10-Nov-03 8:08 
GeneralConvert mpeg-2 Pin
styve9-Nov-03 22:17
styve9-Nov-03 22:17 
GeneralRe: Convert mpeg-2 Pin
Juan Antonio Bermejo9-Nov-03 23:35
Juan Antonio Bermejo9-Nov-03 23:35 
GeneralRe: Convert mpeg-2 Pin
John M. Drescher10-Nov-03 8:27
John M. Drescher10-Nov-03 8:27 
GeneralApp still works but GUI does not update when moved. Pin
BaldwinMartin9-Nov-03 22:03
BaldwinMartin9-Nov-03 22:03 
GeneralRe: App still works but GUI does not update when moved. Pin
jmkhael9-Nov-03 22:10
jmkhael9-Nov-03 22:10 
GeneralRe: App still works but GUI does not update when moved. Pin
BaldwinMartin9-Nov-03 22:12
BaldwinMartin9-Nov-03 22:12 

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.