Take the 2-minute tour ×
Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. It's 100% free, no registration required.

First, some background: I've been programming for about 12 years now. I am intermediate to advance in C# and a couple other managed languages, but never messed with anything native. I understand the concepts, just never had the time to dip into C/C++ and the like.

Now, I am currently enrolled in the Game & Simulation Development course at DeVry, which gave me access to VS2010 (Finally!). After playing around with it, I noticed the default templates for MFC are...well, beyond words. (In a good way. - Referring to the wizards that generate a VS or Office-like interface for you.) Now that I've seen what is possible with MFC, I would love to learn how to use it to make awesome tools, but I don't know where to get started. The MSDN tutorials are pretty much useless, and I've been told that Ivor Horton's VC++ 2010 book is the best, but it doesn't seem to take into account (at least to me based on the more complext UI) the complexity that's added with what the new wizards generate.

So I really have 2 questions:
One, is what is taught in his book sufficent for MFC in general? That would assume the "complexity" I'm perceiving is just cold feet. Two, does anyone know of a good resource to learn how to work with MFC that use the new VS and Office-like interfaces?

Thanks ahead of time.

UPDATE: It seems most of you guys are vehemently opposed to using MFC, so I'll add a bit to this question. The reason I want to use MFC is because the Visual-Studio-like interface seems like a very efficient way to lay out a lot of tools like the property view and such. The MFC wizard in VS2010 gives me all this by default. My ultimate goal is to create an application similar to GameMaker, but with a VS-like interface. (Personal improvement project; I know it's been done to death.) So with that said, is there a way to create a Visual Studio-like shell application without MFC (maybe using Qt, or even with the VS2008 shell)?

share|improve this question

closed as off-topic by MichaelT, World Engineer Jul 29 '13 at 14:22

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "Questions asking us to recommend a tool, library or favorite off-site resource are off-topic for Programmers as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it." – MichaelT, World Engineer
If this question can be reworded to fit the rules in the help center, please edit the question.

    
Keep an eye on the BUILD conference in September this year. It will uncover the future directions of MFC and windows programming model. –  Gulshan Jul 26 '11 at 3:37
    
Not that I'm a fan of .NET, but coming from a C# background and switching to C++ just for MFC is a very strange idea, as MFC is the complete (negative) opposite of .NET regarding useablility and flexibility. If you really want to do GUI development in C++, try looking into Qt. If you only want to use C++ for MFC, you will regret it, just stay to C# and the .NET framework. –  Christian Rau Aug 25 '11 at 7:47

3 Answers 3

You want to use MFC today?????

Even with a slight nod to including a few office-2010 widgets MFC is not really C++ for the 21st century. Yes it's easy to run the wizard to make the first dialog box but as soon as you need to do anything in MFC you are left searching for 10year old blog posts about how to work around it's design features and then searching www.codeproject.com for all the missing functionality.

There are a few MFC books from 10years ago eg. http://www.amazon.com/Programming-Windows-Second-Jeff-Prosise/ They are all out of print so might be expensive used Take a look at Qt if you want to do C++ guis on windows

share|improve this answer
    
And you would recommend creating C++ GUI under Windows using ... –  Job Aug 25 '11 at 3:20
    
@Job exactly what i wanted to ask. Martin must elaborate on the alternatives. –  Wildling Aug 25 '11 at 3:29
1  
I did Qt = qt.nokia.com/products –  Martin Beckett Aug 25 '11 at 3:56
    
I've applied for (what turned out to be) a job as Feature Program Manager MFC, back in 2004. Even back then they admitted that MFC essentially was in maintenance mode. –  MSalters Aug 25 '11 at 11:19

You don't learn MFC, EVER!!!!! WTL, QT, Win32 if you want, but NO, NOT MFC!!!

Been there, done that, not going back! The framework is a nightmare full with legacy hacks, old-skool OOP and tons of gotchas. You will waste months on working around MFC to get stuff done.

share|improve this answer
    
Writing a large Win32 only application, been there done that, not doing it again. Unfortunately MFC is the only thing you have if you ever really intend to develop desktop apps. Killer Feature: Good COM Control support. And important 3rd Party widgets. –  Lothar Dec 4 '12 at 18:41

One, is what is taught in his book sufficent for MFC in general? That would assume the "complexity" I'm perceiving is just cold feet. Two, does anyone know of a good resource to learn how to work with MFC that use the new VS and Office-like interfaces?

I never read the cited book so I can't tell that if it's sufficient or not. Anyway, for the second question, the answer is yes. And no. At the same time.

MFC is a complex beast. It has a lot of overhead. A bizarre amount of boilerplate code.

So, as time goes by, you'll get used to it, then it will feel less complex.

At the same time, you can avoid this all by using another toolkit. I didn't look at the new widgets (I only support a legacy application that uses MFC, updating it to VS2010 is out of question right now) but may other GUI toolkits also offer advanced widgets and are able to create beautiful applications. Qt is a common choice. GTKmm is also nice.

share|improve this answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.