dont be mean im DUMB
dont be mean im DUMB
In dos other than tsr's you basically use 100% cpu time and do not multithread or multitask. You have full access to the hardware. While your proggy is running you have full control of the machine.
Windows on the other hand is basically a giant messaging system. When your proggy is running on windows it does not have direct access to hardware in general and you only get a share of the cpu time. That is because there is other programs running too that need to access the cpu. To program for windows you have to understand the basics of messaging. Whenever an event occurs such as the mouse moving over your proggy, your program recieves a message from windows.You as a programmer decide which messages you want to trap and do things with and you generally let the other messages which are not important to you go through back to windows for default processing.
This is only a very basic overview. Get Programming windows by charles Petzold for a better explanation of this and other aspects of programming for windows.
Free the weed!! Class B to class C is not good enough!!
And the FAQ is here :- http://faq.cprogramming.com/cgi-bin/smartfaq.cgi
The interesting (perverse) thing is that the entire Windaows Application Prgram Interface (API) and all the messages, etc. can be traced back to basic C/C++ (and a little Pascal) code. Some of the C/C++ is readily evident once you look at the API and other times (often) you have to go back multiple "layers" to see how the API snippet is built of C/C++ parts, but it's there. Because the C/C++ of the API is so convoluted at times, several rapid application development forms have been developed like VC++ and BCB, which handle much of "burden" of the API for you (similar to VB). At this level of abstraction, you "almost" don't need to know C/C++ to program in Windows. But if you want to do more than scratch the surface, having a good grounding in C/C++ is an excellent underpinning to tackle the API.
Truly perverse, just about everything you learn about I/O handling in console/DOS based C/C++ is irrelevant in Windows because you are working in a graphical environment, not a text based environment. The control loops, switch statements, classes and other user defined classes, inheritance, arrays, lists, templates, etc., however, are all there.