当前位置: 代码迷 >> VC/MFC >> 编译时遇到这些异常,求教大神
  详细解决方案

编译时遇到这些异常,求教大神

热度:70   发布时间:2016-05-02 03:31:42.0
编译时遇到这些错误,求教大神啊
 error C2143: 语法错误 : 缺少“;”(在“<class-head>”的前面)
 error C4430: 缺少类型说明符 - 假定为 int。注意: C++ 不支持默认 int

部分代码如下:
#if !defined(AFX_COLORDLG_H__8F8B35A7_A4EB_49D5_A6C9_6D93CFBA1D46__INCLUDED_)
#define AFX_COLORDLG_H__8F8B35A7_A4EB_49D5_A6C9_6D93CFBA1D46__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
// ColorDlg.h : header file
//
#include "colourpicker.h"
/////////////////////////////////////////////////////////////////////////////
// 
value class CColorDlg : public CDialog
出错的是最后一行,即value class CColorDlg : public CDialog
------解决思路----------------------
少了个“:”吧?试试
value class CColorDlg :: public CDialog

------解决思路----------------------
//头文件声明
class CColorDlg : public CDialog
{
};

//实现
CColorDlg::CColorDlg(param list)  : CDialog(param list)
{
}
------解决思路----------------------
“value class” 不要 value
  相关解决方案