Game Development Community

Release_1_2_0 and VC6: can't find afxres.h

by Jason Perkins · in Torque Game Engine · 12/20/2003 (7:35 am) · 5 replies

Just did a clean checkout of 1_2_0. Installed VC6 (can't believe I still had the CD) and SP5 and the .cc reg stuff. Tried to build, put it fails with

"C:\Research\torque\vc6\TorqueDemo.rc(10) : fatal error RC1015: cannot open include file 'afxres.h'."

I couldn't find any file named "afxres.h" anywhere in the directory tree. Can anyone help me out here?

Much thanks,

Jason

#1
12/23/2003 (4:39 pm)
Well, I'm not sure that this is a very good answer but I just removed "torqueDemo.rc" (the file containing the include) from the project and was able to complete the build, although the demo app doesn't have an icon. Hopefully this will help someone else get started.
#2
12/23/2003 (5:48 pm)
I had no problems compiling.

That file you seem to be unable to find is a standard Microsoft file.
It should be located at:
\VC98\MFC\Include\
directory within you Mircosoft Visual Studio (AKA its a non torque file.)
#3
12/23/2003 (7:59 pm)
I've run into this problem while compiling other software. If I remember correctly, the reason I ran into it was because I didn't install the MFC stuff when I installed Visual C++. Try re-running MSVC setup and adding the MFC component.
#4
12/24/2003 (1:50 am)
Ah that's it, I didn't install MFC. Thanks!
#5
06/27/2005 (12:19 pm)
> fatal error RC1015: cannot open include file hilite">afxres.h

This include is cynically included by Microsoft when using the project wizards to generate code, as I assume was done for the demo.

If you're like me and allergic to MFC, and really, really don't want to install MFC this is easily fixed:

Just edit the /rc file and change the line

#include "afxres.h"

to

#include "windows.h"


Voila. No need to soil your hard drive with MFC.

--- Kevin