On a 2 GHz machine, it takes a second or two instead of an instant to include windows.h.
Printable View
On a 2 GHz machine, it takes a second or two instead of an instant to include windows.h.
That's odd. It's been a long time, but I remember a Win32 hello world compiling in less than a second, on a 600MHz computer.
Wasn't there a WIN32_LEAN_AND_MEAN thing somewhere?
CornedBee, I didn't know about that. I'll check it out sometime.
Yeah.
#define WIN32_LEAN_AND_MEAN
Kicks out a lot of stuff, like networking and multimedia. Don't mix it with PCHs, though.
The times I got for including windows.h are:
Without WIN32_LEAN_AND_MEAN: 00:02:49
With WIN32_LEAN_AND_MEAN: 00:02:04
My processor is an Athlon X2 3800+ (2 GHz).
Thank you all for your help. It works now.
One last question (although i'm sure to have more in the future).
Is creating a Windows Application alot different than the Console Application programming I have been doing?
For example, I want to try to take my previous Console Applications and turn them into Windows Applications (have a window, buttons, etc.). Is this going to be as simple as adding some code, or am I going to have to basically re-write my programs?
Like, it appears from this code, that instead of using "cout" to ouput text to the screen, I use "TEXT("My first windows app")". So, do cout, if statements, loops, etc. still work?
Thanks.
It's much different from console (which is why everyone is suggested to begin with consoles to learn the basics before venturing on to GUI programs). The basics are still there, of course (string handling, ifs, etc), but cout & co will be useless in a windows app.
And yes, you're pretty much going to have to re-write a lot and add a lot of code to make it work. Windows programming is far from easy.