learning windows and MFC

I took your advice and I used the learncpp tutorial and it was a very good learning tool. I have a good understanding of C++. I need to use language and write programs. Do you have advice on learning windows and MFC? Should I start with a book if so whats a good book? Do you think I should wait and figure a way to use C++ more before jumping into MFC? I appreciate your help and insight.
The one book that should be in everyone's library is Petzold's Programming Windows 5th edition. It is the ideal learning book for a person who feels they have a strong grasp on Native C++, but haven't really started programming in windows yet.

The first couple of chapters are a little dry, like the first chapter is devoted to explaining why wchar_t should be used instead of char, but stick with it, it will show you the basics of getting what you want.

Having said that, it is a book about Windows API, which can be more powerful than MFC, but takes longer to program and at times can be more difficult. I personally prefer API over MFC, but that's going to have to be your decision, I don't have any book suggestions for MFC since I haven't come across any for myself.

The link below is to Windows' development center, they aren't exactly a teaching site, but their pages help define functions and you should look up any new ones there when you run into them.

As far as whether you need to learn C++ better before moving into Windows...
I suggest switching back and forth, learn something new in windows, then try looking up something new in C++. Almost anything you learn in C++ can be used in Windows programming, so the more you know in C++, the better all around.

As long as you know how to use loops, variables, and switches you can start learning windows, but If that is all you know then you will soon find yourself struggling to understand what's going on in windows. I don't know how far along you are, but I suggest at least knowing how to use pointer and references, and how to make functions, classes and deal with file input/output before focusing on windows alone.
Last edited on
I went through my books last night and found MFC in one of them, Ivor Horton's Visual C++ for Beginners, The first 700 pages or so are about native C++ and the last half is about MFC, so it will at least give you a start in MFC.

Topic archived. No new replies allowed.