VC2010 Express에서 포함 파일 'afxres.h'를 열 수 없습니다
VS Express 2010을 사용하여 오래된 프로젝트를 컴파일하려고 하는데이 오류가 발생합니다.
치명적인 오류 RC1015 : 포함 파일 'afxres.h'를 열 수 없습니다. 이 코드에서
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 2 resource.
//
#include "afxres.h"
Windows SDK를 이미 설치했지만 성공하지 못했습니다.
감사!
이 헤더는 MFC 라이브러리의 일부입니다. VS Express 에디션에는 MFC가 포함되어 있지 않습니다. 프로젝트는 MFC를 사용하지 않는 경우 안전하게 대체 할 수 afxres.h
와 windows.h
귀하의에서 terrain2.rc
.
같은 문제가 있었다. C ++ 용 Microsoft Foundation Classes를 설치하여 수정했습니다.
- 스타트
- 프로그램 변경 또는 제거 (유형)
- Microsoft Visual Studio
- 수정
- 'C ++ 용 Microsoft Foundation Classes'를 선택하십시오.
- 최신 정보
나도 비슷한 문제에 직면했다.
치명적인 오류 RC1015 : 포함 파일 'afxres.h'를 열 수 없습니다. 이 코드에서
afxres.h를 Winresrc.h로 바꾸고 IDC_STATIC을 -1로 선언하면 나를 위해 일했습니다. (Visual Studio Premium 2012 사용)
//#include "afxres.h"
#include "WinResrc.h"
#define IDC_STATIC -1
Alternatively you can create your own afxres.h:
#ifndef _AFXRES_H
#define _AFXRES_H
#if __GNUC__ >= 3
#pragma GCC system_header
#endif
#ifdef __cplusplus
extern "C" {
#endif
#ifndef _WINDOWS_H
#include <windows.h>
#endif
/* IDC_STATIC is documented in winuser.h, but not defined. */
#ifndef IDC_STATIC
#define IDC_STATIC (-1)
#endif
#ifdef __cplusplus
}
#endif
#endif
You can also try replace afxres.h with WinResrc.h
managed to fix this by copying the below folder from another Visual Studio setup (non-express)
from C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\atlmfc
to C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\atlmfc
a similar issue is for Visual studio 2015 RC. Sometimes it loses the ability to open RC: you double click but editor do not one menus and dialogs.
Right click on the file *.rc, it will open:
And change as following:
Had similar issue but the message was shown when I tried to open a project solution. What worked for me was:
TOOLS -> Import and Export Settings...-> Reset all settings
참고URL : https://stackoverflow.com/questions/3566018/cannot-open-include-file-afxres-h-in-vc2010-express
'Programing' 카테고리의 다른 글
Python sqlite3 API를 사용하는 테이블, db 스키마, 덤프 등의 목록 (0) | 2020.06.28 |
---|---|
GAC에서 어셈블리를 추출하는 방법은 무엇입니까? (0) | 2020.06.28 |
목록의 키와 기본값이 0으로 된 사전을 어떻게 만들 수 있습니까? (0) | 2020.06.27 |
비동기 네트워크 요청으로 신속한 루프 실행이 완료 될 때까지 기다립니다. (0) | 2020.06.27 |
double을 가장 가까운 정수 값으로 어떻게 변환 할 수 있습니까? (0) | 2020.06.27 |