Application requirement
-
Hello. I have certain programming issue that need to be solved. Im creating an application under win32 console application using VC++2005 :- 1) How can i make the win32 application console invisible/hide during execution. (the black dos window is invisible) 2) Is there any API that can detect an internet connection? I want the application to detect any internet connection is available (wireless or cable). Is there any option or idea to create this mechanism? Maybe it is possible if there is an internet connection available, the application would print a message saying "internet connection available". 3) How can I do a timer in this application? This timer would trigger an event when a time comes. For instance, a message loop will appear every 5 minutes. Thanks
-
Hello. I have certain programming issue that need to be solved. Im creating an application under win32 console application using VC++2005 :- 1) How can i make the win32 application console invisible/hide during execution. (the black dos window is invisible) 2) Is there any API that can detect an internet connection? I want the application to detect any internet connection is available (wireless or cable). Is there any option or idea to create this mechanism? Maybe it is possible if there is an internet connection available, the application would print a message saying "internet connection available". 3) How can I do a timer in this application? This timer would trigger an event when a time comes. For instance, a message loop will appear every 5 minutes. Thanks
Muhamad Hazwan Halim wrote:
- Is there any API that can detect an internet connection?
See if this helps.
Muhamad Hazwan Halim wrote:
- How can I do a timer in this application? This timer would trigger an event when a time comes. For instance, a message loop will appear every 5 minutes.
In a console application?
"Normal is getting dressed in clothes that you buy for work and driving through traffic in a car that you are still paying for, in order to get to the job you need to pay for the clothes and the car and the house you leave vacant all day so you can afford to live in it." - Ellen Goodman
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
-
Hello. I have certain programming issue that need to be solved. Im creating an application under win32 console application using VC++2005 :- 1) How can i make the win32 application console invisible/hide during execution. (the black dos window is invisible) 2) Is there any API that can detect an internet connection? I want the application to detect any internet connection is available (wireless or cable). Is there any option or idea to create this mechanism? Maybe it is possible if there is an internet connection available, the application would print a message saying "internet connection available". 3) How can I do a timer in this application? This timer would trigger an event when a time comes. For instance, a message loop will appear every 5 minutes. Thanks
-
Muhamad Hazwan Halim wrote:
- Is there any API that can detect an internet connection?
See if this helps.
Muhamad Hazwan Halim wrote:
- How can I do a timer in this application? This timer would trigger an event when a time comes. For instance, a message loop will appear every 5 minutes.
In a console application?
"Normal is getting dressed in clothes that you buy for work and driving through traffic in a car that you are still paying for, in order to get to the job you need to pay for the clothes and the car and the house you leave vacant all day so you can afford to live in it." - Ellen Goodman
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
yes. In a console application. Is it possible? What im trying to do is creating such like a software agent which it is invisible to the user. So, this software agent will try to communicate with the server every 5 minutes. If there is connection, then every 5 minutes this software agent will send packets which contains information regarding the client PC. Since im not doing any graphical icons to this software agent, i created the win32 Console application. Is it possible to create a timer so it will send packets to the server every 5 minutes using win32 console application. Any API codes? Thanks
-
Muhamad Hazwan Halim wrote:
How can i make the win32 application console invisible/hide during execution. (the black dos window is invisible)
Why do you need the console window if you are just going to hide it? Maybe you want a windowless application?
Actually i have receive several opinion from google and also other forums saying that why do i need a console application if we were just going to hide it. Thinking and thinking i still could not understand why. :) . As for my application here, actually what im trying to do is a software agent which will communicate and send information packets to the server for every 5 minutes. (This is where i need a timer to solve this). So this software agent is located at client side where it must be invisible to the user for security reason. The reason i choose win32 Console application as the client application side (software agent) is because I dont have any intention to put any graphical icon to the application. It is pure text based. So I just wanna hide the dos window (text based) so that user did not even know that the program is running background. Is there any option @ API that can help me accomplish this requirement?
-
yes. In a console application. Is it possible? What im trying to do is creating such like a software agent which it is invisible to the user. So, this software agent will try to communicate with the server every 5 minutes. If there is connection, then every 5 minutes this software agent will send packets which contains information regarding the client PC. Since im not doing any graphical icons to this software agent, i created the win32 Console application. Is it possible to create a timer so it will send packets to the server every 5 minutes using win32 console application. Any API codes? Thanks
Muhamad Hazwan Halim wrote:
Is it possible to create a timer so it will send packets to the server every 5 minutes using win32 console application.
Yes. You can use
Sleep(300000)
for this. When it returns from sleeping, send the packets.
"Normal is getting dressed in clothes that you buy for work and driving through traffic in a car that you are still paying for, in order to get to the job you need to pay for the clothes and the car and the house you leave vacant all day so you can afford to live in it." - Ellen Goodman
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne