用VC++6.0建了一个WIN API工程,但是想用MFC的类来定义一个对象CFont font,编译有错,求解。
我也放了#include"stdafx.h"了,它的包含的头文件有:#include<afxwin.h>//MFCcoreandstandardcomponents#in...
我也放了#include "stdafx.h"了,它的包含的头文件有:
#include <afxwin.h> // MFC core and standard components
#include <afxext.h> // MFC extensions
#include <afxdisp.h> // MFC Automation classes
#include <afxdtctl.h> // MFC support for Internet Explorer 4 Common Controls
#ifndef _AFX_NO_AFXCMN_SUPPORT
#include <afxcmn.h>
可是编译结果是:
error C2146: syntax error : missing ';' before identifier 'font'
error C2501: 'CFont' : missing storage-class or type specifiers
fatal error C1004: unexpected end of file found
error BK1506 : cannot open file '.\Release\mao.sbr': No such file or directory 展开
#include <afxwin.h> // MFC core and standard components
#include <afxext.h> // MFC extensions
#include <afxdisp.h> // MFC Automation classes
#include <afxdtctl.h> // MFC support for Internet Explorer 4 Common Controls
#ifndef _AFX_NO_AFXCMN_SUPPORT
#include <afxcmn.h>
可是编译结果是:
error C2146: syntax error : missing ';' before identifier 'font'
error C2501: 'CFont' : missing storage-class or type specifiers
fatal error C1004: unexpected end of file found
error BK1506 : cannot open file '.\Release\mao.sbr': No such file or directory 展开
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询