Visual C++ 2008 Express Editionでwin32APIのGUIプログラミングを書いていたのですが、リソースファイルに#include "afxres.h"という記述を書いてビルドした時に下のようなコンパイルエラーが発生しました。
fatal error RC1015: cannot open include file 'afxres.h'
このエラーの解決策は#include "afxres.h"を削除して下の二行を追記する事です。
//#include "afxres.h"
#include <windows.h>
#define IDC_STATIC -1
これでエラーが出ずにビルドできると思います。
・win32APIを使ったwindowsプログラミング入門・初心者のためのお勧め本の紹介
- 猫でもわかるWindowsプログラミング 第3版 (猫でもわかるプログラミングシリーズ)/粂井 康孝
- ¥2,940
- Amazon.co.jp
- Windowsゲームプログラミング 第2版 Game Developer/赤坂 玲音
- ¥2,940
- Amazon.co.jp
参考サイト
・visual c++ 2005 Express Edition への移行メモ