定义一class:
class CAAA
{
public:
void Fun(const CString sStyle,unsigned short uMount,const CString sSituation);
}
定义另一calss:
class CBBB: public CAAA
{
public:
void Cop();
}
在Cop()中调用Fun如下:
Fun(const CString sStyle,unsigned short uMount,const CString sSituation);//已赋值
但出现如下错误:
error C2660: 'CAAA::Fun' : function does not take 3 arguments
但我已经定义过了呀,请赐教!
class CAAA
{
public:
void Fun(const CString sStyle,unsigned short uMount,const CString sSituation);
}
定义另一calss:
class CBBB: public CAAA
{
public:
void Cop();
}
在Cop()中调用Fun如下:
Fun(const CString sStyle,unsigned short uMount,const CString sSituation);//已赋值
但出现如下错误:
error C2660: 'CAAA::Fun' : function does not take 3 arguments
但我已经定义过了呀,请赐教!
解决方案 »
- MFC视图分割之间的通信
- 新手高分求救:ofstream怎么把二维数组的内容,把二维数组看成很多行来存进一个.txt文件?
- C#中载入COM组件
- 求EPROCESS/ETHREAD结构定义
- 听说VC区的高级用户其实都是金玉其外,那个什么其中的,真的是这样的吗??令人心痛!!!
- 怎样用回车把焦点从一个编辑框切换到下一个编辑框?
- 那里有VisiBroker for C++下载
- 怎样把Cstring转换成wchar_t?
- 重金求解,我在win2000下用VC6.0写了一个词法分析器,debug版本运行一切正常,但是release版本到处有问题,请各位超虾给出解答,我出149分哦!!!
- 怎样在vc下设置unicode debug目标(运行在98下)
- 请问UDP中的广播是什么意思?
- 来问个有难度一点问题.
error C2660: 'CAAA::Fun' : function does not take 3 arguments
表明Fun函数在CAAA中已经定义。但参数个数不是三个。你再仔细查查吧
Fun(const CString sStyle,unsigned short uMount,const CString sSituation);
改为:
Fun(sStyle,uMount,sSituation);//参数在函数之前要有值。