afxwin.h missing? windows.h missing? What am *I* missing?

I downloaded and installed Visual C++ EE yesterday. I'm trying to compile some OCX example code that came with a vendor library, and it's failing because "afxwin.h" can't be included. I did a search and neither than file nor "windows.h" exist on my machine.

What am I missing It's been a while since I've tried to write C++ on Windows machines, but aren't these headers fundamental Why aren't they installed with VC++ How can I get them and the other basic stuff needed to do development here What am I missing



Answer this question

afxwin.h missing? windows.h missing? What am *I* missing?

  • dev77

    Thanks, that helped a lot. What does "no-go" mean, though Do you mean that Microsoft now charges for MFC, or that they don't support it at all I searched around some, but couldn't find anything. I wish they'd document this stuff.

  • tronth

    That's a helpful link--thanks. I downloaded VC++ EE from here

    http://msdn.microsoft.com/vstudio/express/visualc/download/

    and the feature page linked (four times) from there doesn't give this kind of information. (There is a link to the PSDK download page, though I didn't understand the significance of that until later.)

    By "bad luck" I meant specifically that I'm having a great deal of trouble trying to compile vendor example code for their OCX and I'm wondering whether part of the problem is that since this code is several years old, some of the features have since been deprecated in the latest VC++ (and therefore maybe I should try to find an older version). (The corresponding VB example code doesn't compile in the current version of VB either, which also adds to this feeling.)

    Apparently MFC is somewhat deprecated, at least in the sense that it wasn't chosen for inclusion in EE, which I'd take as a sign that MS doesn't want newbies to use it anymore. Distributing the PSDK separately is actually a good move, I think, but initially frustrating for prior users of VC++ used to having it bundled along. Finally, in trying to work with this vendor OCX, I was able to add it to the "Toolbar", but it's grayed out there, for no apparent reason and with no explanation given, leading me to feel that this version of VC++ is somehow incompatible with it.

    Some of this can be chalked up to the learning curve, but it seems awfully steep.

  • Greg4408

    That is the platform SDK, is not just for the express edition (it's primarilly an update for older and competing compilers).

    It indeed includes MFC, but most people prefer to not write user interfaces in MFC by hand and it doesn't include the designer


  • Ramzi Aynati

    Sorry, that was slang. "No-go" means: you'll never get that for free with any Express edition. Microsoft will support MFC for many more years. If you think you can just barely afford the Professional edition right now, run to the store and cough up the money. You'll be set for the next two years, if not longer...



  • steven64

    What do you mean bad-luck What is included in Visual C++ EE is well documented. For example

    http://msdn2.microsoft.com/en-us/library/hs24szh9.aspx

    If you are just doing C++ programming then I would get Visual C++ Standard Edition - if you need support for other languages then I would get Visual Studio Professional Edition



  • CrushDaByte

    MFC is definitely not deprecated or going away - we are currently actively working on the next release. The whole point of the Express Edition was to help people learn C++ - I for one feel people should learn C++ before they learn MFC (you'd be surprised by the number of people who try to learn the other way around). It was also meant for downloading so even in these days of broadband we had to limit the size - hence the separate PSDK download and the exclusion of MFC. If you are doing "professional" development then the Express Edition is really not the best product - you should get either the Standard Edition or one of the Visual Studio editions.

  • Damann

    Thanks for your help. I may have to do that--it'd be my employers money anyway, and probably better for them in the long run. I don't mind the $$ so much, but it'd be nice if they'd be explicit about what EE does and doesn't do.

    Which version should I get Given my bad luck so far with Visual C++ 2005 Express Edition, should I try for an older version

    I almost got my program working with the PSDK, but I'm having a missing library problem, which I'll put in a separate thread.



  • jregent

    A quick word about the MFC version that is included with the Platform SDK: it is only suitable for 64-bit builds, don't try to use it for 32-bit builds. I think Express only includes the 32-bit compiler so it's a "no-go". There have been a few attempts at porting the 64-bit version to 32-bit but they were abandoned. Porting the 64-bit version of ATL has however been successful. All and all, by the time you're done messing with this, you'd have earned yourself an RTM version.


  • r.guerzoni

    You're missing MFC to get afxwin.h and the Platform SDK for <windows.h>. They don't come included with the Express edition. MFC is a no-go but you can get the Platform SDK; search this forum for "SDK".



  • Vijaya Kumar M

    The SDK for Visual C++ EE is available for free download at

    http://www.microsoft.com/downloads/details.aspx FamilyID=484269E2-3B89-47E3-8EB7-1F2BE6D7123A&displaylang=en&Hash=8XQxtADLl8bKnNDG4HxHXgHk1xyMug9zwtShZJACrt2SrwpMEHVXpAGmi8MrB%2b2Xi4t9wH3oAuaYKj1QvnXp%2fQ%3d%3d#filelist

    I'm in the process of downloading it right now. It comes in the form of about 18 files, 25 mb each. What a hassle.... but it's free!!

    Zorweb


  • afxwin.h missing? windows.h missing? What am *I* missing?