Click here to Skip to main content
15,895,011 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
Generalneed to get tenth of seconds from system time using CTime Pin
4-Mar-02 5:20
suss4-Mar-02 5:20 
GeneralRe: need to get tenth of seconds from system time using CTime Pin
Tim Smith4-Mar-02 5:27
Tim Smith4-Mar-02 5:27 
GeneralRe: need to get tenth of seconds from system time using CTime Pin
Ravi Bhavnani4-Mar-02 5:28
professionalRavi Bhavnani4-Mar-02 5:28 
GeneralFocus problem on windows 2000 Pin
4-Mar-02 4:47
suss4-Mar-02 4:47 
GeneralRe: Focus problem on windows 2000 Pin
Joaquín M López Muñoz4-Mar-02 4:58
Joaquín M López Muñoz4-Mar-02 4:58 
GeneralRe: Focus problem on windows 2000 Pin
4-Mar-02 22:16
suss4-Mar-02 22:16 
GeneralRe: Focus problem on windows 2000 Pin
Joaquín M López Muñoz4-Mar-02 22:35
Joaquín M López Muñoz4-Mar-02 22:35 
QuestionHow to make a batch file interactive Pin
Dave Midgley4-Mar-02 4:18
Dave Midgley4-Mar-02 4:18 
I'm trying to make an interactive batch file (.cmd) to run under Windows NT. The obvious way is to have a program that displays a prompt and sets an environment variable with the response - the batch file can then access the input value via the environment variable (as %environmentvariable%), however
1) using _setenv() only alters the environment for the current program, so the batch file that ran the program does not see the new variable; conversely
2) altering the registry where the environment variables are kept (HKEY_CURRENT_USER\Environment etc.) has no effect until a new DOS shell is started, so the batch file that ran the program does not see the new variable;
3) the old DOS method of getting the PSP and walking up the environment areas isn't allowed under NT (and there's never enough space in the environment area anyway);
If anyone knows how to write a program that can do this, or any other way of making a batch file interactive, I'd love to hear about it.
(PS I know that using VBS or some other scripting language is the right way to go, but I need this to run on any NT Server machine, and the CMD processor seems to be the only scripting engine that is guaranteed to be available)
Thanks


Dave
AnswerRe: How to make a batch file interactive Pin
Tomasz Sowinski4-Mar-02 4:32
Tomasz Sowinski4-Mar-02 4:32 
GeneralRe: How to make a batch file interactive Pin
Dave Midgley4-Mar-02 4:38
Dave Midgley4-Mar-02 4:38 
GeneralRe: How to make a batch file interactive Pin
Tomasz Sowinski4-Mar-02 4:47
Tomasz Sowinski4-Mar-02 4:47 
AnswerRe: How to make a batch file interactive Pin
56789012344-Mar-02 5:12
56789012344-Mar-02 5:12 
GeneralCToolBar Problem Pin
4-Mar-02 3:55
suss4-Mar-02 3:55 
GeneralRe: CToolBar Problem Pin
4-Mar-02 4:01
suss4-Mar-02 4:01 
GeneralMFC dll acting strange when using &Data in exported f() parameters Pin
4-Mar-02 3:24
suss4-Mar-02 3:24 
GeneralRe: MFC dll acting strange when using &Data in exported f() parameters Pin
Prem Kumar4-Mar-02 3:33
Prem Kumar4-Mar-02 3:33 
GeneralRe: MFC dll acting strange when using &Data in exported f() parameters Pin
Tomasz Sowinski4-Mar-02 3:41
Tomasz Sowinski4-Mar-02 3:41 
Generalsomeone who knows about blocking a packet at network layer using vc++ Pin
4-Mar-02 3:15
suss4-Mar-02 3:15 
GeneralManually opening a document Pin
benjymous4-Mar-02 3:02
benjymous4-Mar-02 3:02 
GeneralRe: Manually opening a document Pin
Prem Kumar4-Mar-02 3:26
Prem Kumar4-Mar-02 3:26 
GeneralCDateTimeCtrl and CTime Pin
User 66584-Mar-02 2:59
User 66584-Mar-02 2:59 
GeneralRe: CDateTimeCtrl and CTime Pin
Prem Kumar4-Mar-02 3:11
Prem Kumar4-Mar-02 3:11 
GeneralRe: CDateTimeCtrl and CTime Pin
Tomasz Sowinski4-Mar-02 3:26
Tomasz Sowinski4-Mar-02 3:26 
GeneralRe: CDateTimeCtrl and CTime Pin
Prem Kumar4-Mar-02 3:28
Prem Kumar4-Mar-02 3:28 
GeneralRe: CDateTimeCtrl and CTime Pin
Tomasz Sowinski4-Mar-02 3:30
Tomasz Sowinski4-Mar-02 3:30 

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.