Win32 programming, where to start?
-
Normally I make everything with MFC, but the large mfc library and all the wizzards sometimes annoy me, so I'm going to try to make something -pure-, a normal win32 program. But now I noticed many things I always used appear to be mfc only (TRACE for example). So what is a good place to start? Are there any good Tutorials, or books which cover the basics of win32 well? All kinds of questions arose, such as... o Where to define my variables? (I used to define them in the classes in which they were used, and I try to avoid to make them global) o What functions to use to manipulate strings? (wsprintf uses LPTSTR as it should, but are there LPTSTR equivalents of sscanf and such?) If you could give some advice I would be very grateful. Thanks in advance! - Griffith
-
Normally I make everything with MFC, but the large mfc library and all the wizzards sometimes annoy me, so I'm going to try to make something -pure-, a normal win32 program. But now I noticed many things I always used appear to be mfc only (TRACE for example). So what is a good place to start? Are there any good Tutorials, or books which cover the basics of win32 well? All kinds of questions arose, such as... o Where to define my variables? (I used to define them in the classes in which they were used, and I try to avoid to make them global) o What functions to use to manipulate strings? (wsprintf uses LPTSTR as it should, but are there LPTSTR equivalents of sscanf and such?) If you could give some advice I would be very grateful. Thanks in advance! - Griffith
"programming windows 95" (not sure about the title) by charlez petzold (not sure bout the spelling :) ) might be a good book. But i would suggest you look at WTL instead, it is a lightwight framework for the win32 api. (or for the windowing part at least) /Magnus
- A dog who attends a flea circus most likely will steal the whole show
-
"programming windows 95" (not sure about the title) by charlez petzold (not sure bout the spelling :) ) might be a good book. But i would suggest you look at WTL instead, it is a lightwight framework for the win32 api. (or for the windowing part at least) /Magnus
- A dog who attends a flea circus most likely will steal the whole show
Thanks, I'll check it out.
-
Normally I make everything with MFC, but the large mfc library and all the wizzards sometimes annoy me, so I'm going to try to make something -pure-, a normal win32 program. But now I noticed many things I always used appear to be mfc only (TRACE for example). So what is a good place to start? Are there any good Tutorials, or books which cover the basics of win32 well? All kinds of questions arose, such as... o Where to define my variables? (I used to define them in the classes in which they were used, and I try to avoid to make them global) o What functions to use to manipulate strings? (wsprintf uses LPTSTR as it should, but are there LPTSTR equivalents of sscanf and such?) If you could give some advice I would be very grateful. Thanks in advance! - Griffith
I think you might be better looking into WTL first before moving to straight Win32 API. WTL is a much smaller and cleaner framework than MFC. The Charles Petzold book will give you a good grounding in Win32 programming. Not sure of the current title as my copy is Programming Windows 3.1 Michael :-) Logic, my dear Zoe, merely enables one to be wrong with authority. - The Doctor
-
Normally I make everything with MFC, but the large mfc library and all the wizzards sometimes annoy me, so I'm going to try to make something -pure-, a normal win32 program. But now I noticed many things I always used appear to be mfc only (TRACE for example). So what is a good place to start? Are there any good Tutorials, or books which cover the basics of win32 well? All kinds of questions arose, such as... o Where to define my variables? (I used to define them in the classes in which they were used, and I try to avoid to make them global) o What functions to use to manipulate strings? (wsprintf uses LPTSTR as it should, but are there LPTSTR equivalents of sscanf and such?) If you could give some advice I would be very grateful. Thanks in advance! - Griffith
The Petzold book is an excellent tutorial. Btw, you can (and should!) continue to use classes. /ravi Let's put "civil" back into "civilization" http://www.ravib.com ravib@ravib.com
-
The Petzold book is an excellent tutorial. Btw, you can (and should!) continue to use classes. /ravi Let's put "civil" back into "civilization" http://www.ravib.com ravib@ravib.com
Thanks, I'll see if I can find it. Oh.. and I didn't want to stop using classes, only the CString, CDialog, and those are the ones I wasn't particually fond of.
-
Thanks, I'll see if I can find it. Oh.. and I didn't want to stop using classes, only the CString, CDialog, and those are the ones I wasn't particually fond of.
STL will handle the string classes using std::string. WTL will give you a nice thin framework for CDialog. You could write your own framework, do a search for Windows++ for an example. Michael :-) Logic, my dear Zoe, merely enables one to be wrong with authority. - The Doctor
-
I think you might be better looking into WTL first before moving to straight Win32 API. WTL is a much smaller and cleaner framework than MFC. The Charles Petzold book will give you a good grounding in Win32 programming. Not sure of the current title as my copy is Programming Windows 3.1 Michael :-) Logic, my dear Zoe, merely enables one to be wrong with authority. - The Doctor
Would you happen to know any good books which cover the WTL basics then?
-
Normally I make everything with MFC, but the large mfc library and all the wizzards sometimes annoy me, so I'm going to try to make something -pure-, a normal win32 program. But now I noticed many things I always used appear to be mfc only (TRACE for example). So what is a good place to start? Are there any good Tutorials, or books which cover the basics of win32 well? All kinds of questions arose, such as... o Where to define my variables? (I used to define them in the classes in which they were used, and I try to avoid to make them global) o What functions to use to manipulate strings? (wsprintf uses LPTSTR as it should, but are there LPTSTR equivalents of sscanf and such?) If you could give some advice I would be very grateful. Thanks in advance! - Griffith
I've read "Win32 Programming" by Brent Rector and Joseph M. Newcomer. It's an excellent read and a great reference book. My copy started to fall apart because I used it so much when learning pure Win32 programming. Also, Joseph is a registered CPian and well-respected programmer. Take a look at some of his articles to see the quality of his work. This is also reflected in the book. Jeremy L. Falcon Homepage : Sonork = 100.16311
"Victims falling under chains ~ You hear them crying dying pains The fist of terrors breaking through ~ Now there's nothing you can do" Song: Phantom Lord - Album: Kill 'em All - Artist: Metallica