Thread: Good book recommendation?

  1. #1
    Pupil
    Join Date
    Oct 2005
    Location
    Toledo
    Posts
    27

    Question Good book recommendation?

    Hello, I am interested in learning how to use the program, Microsoft Visual C++, I am familiar* with C++ syntax and I currently use the DevC++ compiler.

    My school is not offering any windows programming classes this upcoming winter semester. So, I have to wait a year before I can take any classes on windows programming. I’m tired of making programs that run in a “dos shell’ and I want to start making GUIs for my programs.

    Could anyone recommend a BEGNNER book on windows programming in C++?

  2. #2
    Skunkmeister Stoned_Coder's Avatar
    Join Date
    Aug 2001
    Posts
    2,572
    you will need these 2 books:-

    Programming windows by charles petzold.
    Programming applications for microsoft windows by jeff richter.

    From there your best reference after that is probably msdn
    Free the weed!! Class B to class C is not good enough!!
    And the FAQ is here :- http://faq.cprogramming.com/cgi-bin/smartfaq.cgi

  3. #3
    Registered User
    Join Date
    Apr 2003
    Posts
    2,663
    I am familiar* with C++ syntax
    You have to be a lot more familiar with C++ than that to be able to make GUI's with Visual C++. You need to thoroughly understand pointers, classes, inheritance, and virtual functions.

    "Ivor Horton's Beginning Visual C++ 6" - the first 12 chapters are a tutorial on the C++ language, and the next 12 chapters cover windows programming with Visual C++. Even then, windows programming with Visual C++ is a very difficult subject, and it can take several attempts to learn it over several years before it will start making some sense.
    Last edited by 7stud; 10-14-2005 at 12:03 PM.

  4. #4
    Hardware Engineer
    Join Date
    Sep 2001
    Posts
    1,398

    Thumbs up Petzold !

    The Petzold book assumes you already know C, and he takes you from there. It's written in a tutorial style, but it makes a great reference too. Almost every Windows Programmer has this book. (I was shocked when I first cracked-open the book, and "Hello Windows" was 2 pages of unfamiliar code!)

    He does use C, but this isn't much of an issue because the Windows API is a set of functions, structures, and constants that can be dropped-into a C or C++ program. (You will have to use C-style strings, or convert your C++ string objects before passing them to any WinAPI functions.)

    I don't own the Richter book. I think it's more advanced than Petsold, and it seems to be out-of-print.

    Until you get your book(s), check-out the excellent Forgers Windows Programming Tutorial.

    In case you're not aware, your Dev-C++ IDE can make full Windows GUI programs. But, if your school is standardized on MSVC++, it wouldn't hurt to get a jump-start learning to use it. It's always good to use the same compiler as the instructor.

    EDIT -
    WARNING -
    I don't own the Horton book, and I've never used MFC... So, I don't know what I'm talking about here...

    Horton uses MFC, and Petzold uses the WinAPI. (Forger's uses the WinAPI too.) You might want to find out what your class will cover next year.

    MFC packages the WinAPI functions, and It's supposed to be easier to write a Windows program with it. However, I'm not so sure its easier to learn... if you don't already know the API.

    I'm sure it's often better to use MFC than to "re-invent the wheel". But personally, I'm trying to learn what's going-on under the hood.

    You need to thoroughly understand pointers, classes, inheritance, and virtual functions.
    The WinAPI doesn't require classes, inheritance, or virtual functions. You do need a good understanding of functions, structures and pointers. And, if you want to write a program that not only "looks good", but one that does something useful and runs efficiently, then you do need a good understanding of standard C++.

    And like 7stud said, this is a difficult subject. If you jump into Windows GUI too soon, you could easily get off-track... sepnding all your time on Windows stuff while neglecting to learn (standard) C++.
    Last edited by DougDbug; 10-14-2005 at 01:30 PM.

  5. #5
    Pupil
    Join Date
    Oct 2005
    Location
    Toledo
    Posts
    27

    thank you

    Thank you for the help. I agree, maybe I should not try to rush things and first build a solid foundation on C++ logic first. I’ll work on this first and then study Visual C++ as a summer project.

    You all are great, and I appreciate the help

  6. #6
    Registered User
    Join Date
    Sep 2005
    Posts
    15
    Man if youre tired of DOS and want to make GUI apps, Visual Basic is the way to go. Ive studied it and its really easy and you can make some good GUI apps with it.

  7. #7
    Registered User Dante Shamest's Avatar
    Join Date
    Apr 2003
    Posts
    970
    Quote Originally Posted by aznboi
    Man if youre tired of DOS and want to make GUI apps, Visual Basic is the way to go. Ive studied it and its really easy and you can make some good GUI apps with it.
    Which version of Visual Basic?

    VB6? It's already dead. Microsoft no longer supports it.

    Visual Basic .NET? It can't be compiled to native code, plus it's a totally different language from the old VB. Anyway, you can access the same class libraries from C++ or C#.

    @ original poster
    Here's a list of Windows tutorials that you might find helpful.
    Last edited by Dante Shamest; 10-14-2005 at 05:55 PM.

  8. #8
    Registered User
    Join Date
    Sep 2005
    Posts
    15
    what do u mean its dead? i sitll use it

  9. #9
    Dump Truck Internet valis's Avatar
    Join Date
    Jul 2005
    Posts
    357
    I have 2 of Ivor Horton's books, the C++ book is really great but the Windows GUI book is total trash, don't start out learning MFC, you really need to understand the underlying structure (that's code for winapi) you're working with unless you want to architect scat.

    When I first learned to program for windows it was with mfc and later learned the api, which I regret as after learning the api mfc was rather natural and easy (was pretty confusing when I was starting out) while the inverse is not true.

  10. #10
    Registered User Dante Shamest's Avatar
    Join Date
    Apr 2003
    Posts
    970
    what do u mean its dead? i sitll use it
    Because future versions of Visual Basic will be for the .NET framework only. It is not at all compatible with older version like VB6. In other words, VB6 is the last in the line of the old Visual Basic language.

    You can still use VB6, but I definitely won't recommend a new programmer to learn it, since it's only going to be less useful in the future.

  11. #11
    Registered User
    Join Date
    Sep 2005
    Posts
    15
    really? darn i just learned it over the summer lol...

  12. #12
    Pupil
    Join Date
    Oct 2005
    Location
    Toledo
    Posts
    27

    thank you

    I have a copy of Visual Basic.net; I bought it from the school book store, because of how cheap it was after my student discount.

    But, I know very little about visual basic, and I don’t want to learn two programming languages at once. Plus, the sky is the limit with C++.

    I absolutely love it and all I care about is obtaining as much information as possible about this language. I’m addicted! All I think about is someday writing mind blowing games and great applications that everyone could truly enjoy. I just need to take this process one step at a time so I don’t get discouraged. I want to write GUIs! But, I will listen to others and do what is necessary first.

  13. #13
    Registered User
    Join Date
    Jul 2005
    Posts
    14

    Why not try Qt?

    Here is a nice book and you will learn how to make platformindependent progarms.

    http://www.phptr.com/content/images/...hette_book.pdf

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. recommendation for a good OOP book
    By Mario F. in forum C++ Programming
    Replies: 2
    Last Post: 06-15-2006, 04:28 PM
  2. Good vectors/planes book
    By jverkoey in forum A Brief History of Cprogramming.com
    Replies: 4
    Last Post: 11-19-2005, 02:43 PM
  3. a good book about c??
    By GanglyLamb in forum C Programming
    Replies: 19
    Last Post: 12-28-2002, 09:35 AM
  4. Books on C and C++
    By kermi3 in forum A Brief History of Cprogramming.com
    Replies: 16
    Last Post: 10-28-2002, 04:18 PM
  5. Lookinf for a good NON beginner book
    By Unregistered in forum C Programming
    Replies: 5
    Last Post: 08-30-2002, 07:17 PM