VC++编程问题
这个错误是不我VC版本不行,缺少的东西?如何解决?D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(184):errorC2039:'FindStrin...
这个错误是不我VC版本不行,缺少的东西?如何解决?
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(184) : error C2039: 'FindString' : is not a member of 'CString'
c:\program files\microsoft visual studio\vc98\mfc\include\afx.h(368) : see declaration of 'CString'
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(186) : error C2039: 'AddString' : is not a member of 'CString'
c:\program files\microsoft visual studio\vc98\mfc\include\afx.h(368) : see declaration of 'CString'
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(193) : error C2039: 'SetItemDataPtr' : is not a member of 'CString'
c:\program files\microsoft visual studio\vc98\mfc\include\afx.h(368) : see declaration of 'CString'
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(195) : error C2039: 'SetCurSel' : is not a member of 'CString'
c:\program files\microsoft visual studio\vc98\mfc\include\afx.h(368) : see declaration of 'CString'
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(196) : error C2065: 'OnChangeCombo' : undeclared identifier
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(201) : error C2039: 'GetCurSel' : is not a member of 'CString'
c:\program files\microsoft visual studio\vc98\mfc\include\afx.h(368) : see declaration of 'CString'
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(204) : error C2228: left of '.ResetContent' must have class/struct/union type
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(206) : error C2039: 'GetItemDataPtr' : is not a member of 'CString'
c:\program files\microsoft visual studio\vc98\mfc\include\afx.h(368) : see declaration of 'CString'
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(209) : error C2228: left of '.AddString' must have class/struct/union type
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(211) : error C2228: left of '.AddString' must have class/struct/union type
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(214) : error C2228: left of '.AddString' must have class/struct/union type
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(223) : error C2039: 'GetCount' : is not a member of 'CString'
c:\program files\microsoft visual studio\vc98\mfc\include\afx.h(368) : see declaration of 'CString'
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(224) : error C2039: 'GetItemDataPtr' : is not a member of 'CString'
c:\program files\microsoft visual studio\vc98\mfc\include\afx.h(368) : see declaration of 'CString'
InputDlg.cpp
D:\程序制作\Ex_Ctrls1\InputDlg.cpp(65) : error C2039: 'trimLeft' : is not a member of 'CString'
c:\program files\microsoft visual studio\vc98\mfc\include\afx.h(368) : see declaration of 'CString'
D:\程序制作\Ex_Ctrls1\InputDlg.cpp(80) : error C2039: 'SetRange' : is not a member of 'CScrollBar' 展开
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(184) : error C2039: 'FindString' : is not a member of 'CString'
c:\program files\microsoft visual studio\vc98\mfc\include\afx.h(368) : see declaration of 'CString'
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(186) : error C2039: 'AddString' : is not a member of 'CString'
c:\program files\microsoft visual studio\vc98\mfc\include\afx.h(368) : see declaration of 'CString'
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(193) : error C2039: 'SetItemDataPtr' : is not a member of 'CString'
c:\program files\microsoft visual studio\vc98\mfc\include\afx.h(368) : see declaration of 'CString'
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(195) : error C2039: 'SetCurSel' : is not a member of 'CString'
c:\program files\microsoft visual studio\vc98\mfc\include\afx.h(368) : see declaration of 'CString'
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(196) : error C2065: 'OnChangeCombo' : undeclared identifier
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(201) : error C2039: 'GetCurSel' : is not a member of 'CString'
c:\program files\microsoft visual studio\vc98\mfc\include\afx.h(368) : see declaration of 'CString'
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(204) : error C2228: left of '.ResetContent' must have class/struct/union type
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(206) : error C2039: 'GetItemDataPtr' : is not a member of 'CString'
c:\program files\microsoft visual studio\vc98\mfc\include\afx.h(368) : see declaration of 'CString'
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(209) : error C2228: left of '.AddString' must have class/struct/union type
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(211) : error C2228: left of '.AddString' must have class/struct/union type
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(214) : error C2228: left of '.AddString' must have class/struct/union type
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(223) : error C2039: 'GetCount' : is not a member of 'CString'
c:\program files\microsoft visual studio\vc98\mfc\include\afx.h(368) : see declaration of 'CString'
D:\程序制作\Ex_Ctrls1\Ex_CtrlsDlg.cpp(224) : error C2039: 'GetItemDataPtr' : is not a member of 'CString'
c:\program files\microsoft visual studio\vc98\mfc\include\afx.h(368) : see declaration of 'CString'
InputDlg.cpp
D:\程序制作\Ex_Ctrls1\InputDlg.cpp(65) : error C2039: 'trimLeft' : is not a member of 'CString'
c:\program files\microsoft visual studio\vc98\mfc\include\afx.h(368) : see declaration of 'CString'
D:\程序制作\Ex_Ctrls1\InputDlg.cpp(80) : error C2039: 'SetRange' : is not a member of 'CScrollBar' 展开
6个回答
展开全部
你的程序用的是新版的MFC, 但是你的VC里带的版本是旧版的. 要么安装新版的VC, 要么把新版的MFC弄过来. 不过建议安装新版的VC, 新版的MFC代码旧版的VC编译器不一定能支持. 尤其是IO stream库之类的旧版没有用模板的.
追问
新版MFC 是啥样的。。。在哪下载
追答
没有单独的下载吧. MFC和VC是配套发行的, 你需要到已经安装新版VC的电脑里面拷. 如果没有的话还是直接装新版的VC, 要是有需要用旧版的VC的话需要设置下旧版VC的Include和Lib到新版的路径里, 然后移除旧版MFC的部分就可以了. 旧版的为带有c:\program files\microsoft visual studio\vc98\mfc\* 的条目, 必须移除. 新版的MFC路径也差不多.
本回答被提问者采纳
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
展开全部
你的函数写得不太对啊,没听说CString有FindString()但是有find。。。。
可能的情况就是,你可能自己实现了CString,但是你没有把自己实现的文件include进来。
可能的情况就是,你可能自己实现了CString,但是你没有把自己实现的文件include进来。
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
展开全部
同上..在D:\程序制作\Ex_Ctrls1\这个文件夹里面搜索一下CString和CScrollBar吧..然后把.h包含一下..没搜到就说明你下的源码不完整..
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
展开全部
你百度搜 VS2005啊 2008 啊 这些都是新的
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询