Suppress DOS screen

K

KC Wong

Hello,

I have the following code,
during system boot up, I need to run some DOS programs, and they will
end automatically. My question is how to suppress the screen messages
so that users are unaware of the DOS programs? The client PCs are
using Windows 98.

#include <atlbase.h>
#include<iostream>
using namespace std;

void main(){
//pause for some seconds
system("TYPE NUL | CHOICE.COM /N /CY /TY,5 >NUL");

//start running
system("c:\\test.exe");
}


Thanks!

KC
 
V

Victor Bazarov

KC said:
I have the following code,
during system boot up, I need to run some DOS programs, and they will
end automatically. My question is how to suppress the screen messages
so that users are unaware of the DOS programs? The client PCs are
using Windows 98.

<offtopic>
Make them _Windows_ programs. RTFM about the difference between
"console" subsystem and "windows" subsystem.
#include <atlbase.h>

No such C++ header
#include<iostream>
using namespace std;

void main(){

No such thing as "void main" in C++.
//pause for some seconds
system("TYPE NUL | CHOICE.COM /N /CY /TY,5 >NUL");

//start running
system("c:\\test.exe");
}

When posing in comp.lang.c++ try to stay within limits of the Standard
C++ language. If you need help understanding what it is, just ask.

V
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,057
Latest member
KetoBeezACVGummies

Latest Threads

Top