Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I learn Visual C++? [closed]

Tags:

c++

visual-c++

I'm interested in learning how to program using Microsoft's Visual C++ for Windows. In particular, I want to know how to make applications for the Windows platform.

I'm already a professional programmer. I know the C and C++ languages as well as many other languages in depth, I just haven't done any Windows programming before, so I don't need an introduction to C/C++ or programming. I'm also interested in writing programs for the latest versions of Windows, including Windows 7, and MFC sounds outdated.

Looking for books, I already found elsewhere on StackOverflow a recommendation for Petzold's "Programming Windows" book, but that's from 1998 -- is it really still applicable?

My questions are:

  • What web sites do you recommend as references?
  • What web sites do you recommend as tutorials?
  • Are there any books or e-books on the subject?
  • What options are available as far as frameworks is concerned? Vanilla, .NET, Native, MFC, what are the differences, and which is what?
like image 793
dionyziz Avatar asked Sep 24 '10 23:09

dionyziz


People also ask

Can I learn C in Visual Studio?

Yes, you very well can learn C using Visual Studio. Visual Studio comes with its own C compiler, which is actually the C++ compiler. Just use the . c file extension to save your source code.

Is Visual C++ hard to learn?

C++ is known to be one of the most difficult programming languages to learn over other popular languages like Python and Java. C++ is hard to learn because of its multi-paradigm nature and more advanced syntax.

Is Visual C free?

A fully-featured, extensible, free IDE for creating modern applications for Android, iOS, Windows, as well as web applications and cloud services.


3 Answers

WPF is the latest UI framework from Microsoft, it has lots of advantages over System.Windows.Forms which is its predecessor in .NET. It might be easiest to learn C# and do the UI stuff in WPF, and call out to native C++, only as needed. If you want to stick to only C++, you can also use managed C++ (C++/CLI) with both of the .NET GUI framework technologies.

If you want native-only C++, then Qt is a rather nice framework. Don't use MFC unless you really need to, like for legacy support. You can also write your own C++ wrapper classes for the Win32 API, but that's more work than is usually worth, unless for the very small application.

If you are writing brand new code, I'd recommend learning C# instead and using WPF. Having a managed application has lots of benefits for development, and C# is easier to work with than managed C++.

Any recent Windows programming books by Petzold or Richter will do ya fine.

like image 108
Chris O Avatar answered Oct 01 '22 03:10

Chris O


If you do some searching on here and the internet in general, you should find various discussions already about GUI frameworks for Windows. For example, this question.

Beyond the raw API and MFC (neither of which are recommended anymore by most people), the 3 biggest names are Qt, WxWidgets, and GTK. I know almost nothing about GTK, but among the others my preference is Qt. It just seems to go above and beyond the others in what it offers.

However, as others have already mentioned, you may want to seriously consider learning something like C# and using all the things that .Net provides (such as WPF). There are many aspects of those technologies that are well suited for GUI development. And of course it is well integrated into Visual Studio.

like image 38
TheUndeadFish Avatar answered Oct 01 '22 03:10

TheUndeadFish


Visual C++ is a compiler for C++, it's not a framework. If you just want to get a huge headstart save yourself the trouble and either start with C++.net or C#. Otherwise you will need a book on Win32/MFC/Qt/Wx or any of the other toolkits for writing C++ GUI apps on Windows.

like image 20
Novikov Avatar answered Oct 01 '22 04:10

Novikov