24小时热门版块排行榜    

查看: 763  |  回复: 2

zyj8119

木虫 (著名写手)

[求助] 一个MFC的小项目出了问题,求高手帮忙。。

MFC的小项目在这里:
回复此楼

» 猜你喜欢

» 本主题相关价值贴推荐,对您同样有帮助:

好好学习,天天向上。
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖

zyj8119

木虫 (著名写手)

引用回帖:
Originally posted by zyj8119 at 2011-05-07 20:52:06:
MFC的小项目在这里:

--------------------Configuration: GPACalculator - Win32 Debug--------------------
Compiling...
GPACalculator.cpp
c:\program files\microsoft visual studio\myprojects\gpacalculator\gpacalculatordlg.h(29) : error C2535: 'double __thiscall CGPACalculatorDlg::GetSDPoint(double)' : member function already defined or declared
        c:\program files\microsoft visual studio\myprojects\gpacalculator\gpacalculatordlg.h(26) : see declaration of 'GetSDPoint'
c:\program files\microsoft visual studio\myprojects\gpacalculator\gpacalculatordlg.h(64) : error C2535: 'void __thiscall CGPACalculatorDlg::SpliterString(class CString,double &,double &' : member function already defined or declared
        c:\program files\microsoft visual studio\myprojects\gpacalculator\gpacalculatordlg.h(61) : see declaration of 'SpliterString'
c:\program files\microsoft visual studio\myprojects\gpacalculator\gpacalculatordlg.h(82) : error C2535: 'void __thiscall CGPACalculatorDlg::GatherData(void)' : member function already defined or declared
        c:\program files\microsoft visual studio\myprojects\gpacalculator\gpacalculatordlg.h(80) : see declaration of 'GatherData'
c:\program files\microsoft visual studio\myprojects\gpacalculator\gpacalculatordlg.h(107) : error C2535: 'void __thiscall CGPACalculatorDlg::ChangeType(int)' : member function already defined or declared
        c:\program files\microsoft visual studio\myprojects\gpacalculator\gpacalculatordlg.h(105) : see declaration of 'ChangeType'
c:\program files\microsoft visual studio\myprojects\gpacalculator\gpacalculatordlg.h(162) : error C2535: 'void __thiscall CGPACalculatorDlg::SetEditRead(bool)' : member function already defined or declared
        c:\program files\microsoft visual studio\myprojects\gpacalculator\gpacalculatordlg.h(160) : see declaration of 'SetEditRead'
GPACalculatorDlg.cpp
c:\program files\microsoft visual studio\myprojects\gpacalculator\gpacalculatordlg.h(29) : error C2535: 'double __thiscall CGPACalculatorDlg::GetSDPoint(double)' : member function already defined or declared
        c:\program files\microsoft visual studio\myprojects\gpacalculator\gpacalculatordlg.h(26) : see declaration of 'GetSDPoint'
c:\program files\microsoft visual studio\myprojects\gpacalculator\gpacalculatordlg.h(64) : error C2535: 'void __thiscall CGPACalculatorDlg::SpliterString(class CString,double &,double &' : member function already defined or declared
        c:\program files\microsoft visual studio\myprojects\gpacalculator\gpacalculatordlg.h(61) : see declaration of 'SpliterString'
c:\program files\microsoft visual studio\myprojects\gpacalculator\gpacalculatordlg.h(82) : error C2535: 'void __thiscall CGPACalculatorDlg::GatherData(void)' : member function already defined or declared
        c:\program files\microsoft visual studio\myprojects\gpacalculator\gpacalculatordlg.h(80) : see declaration of 'GatherData'
c:\program files\microsoft visual studio\myprojects\gpacalculator\gpacalculatordlg.h(107) : error C2535: 'void __thiscall CGPACalculatorDlg::ChangeType(int)' : member function already defined or declared
        c:\program files\microsoft visual studio\myprojects\gpacalculator\gpacalculatordlg.h(105) : see declaration of 'ChangeType'
c:\program files\microsoft visual studio\myprojects\gpacalculator\gpacalculatordlg.h(162) : error C2535: 'void __thiscall CGPACalculatorDlg::SetEditRead(bool)' : member function already defined or declared
        c:\program files\microsoft visual studio\myprojects\gpacalculator\gpacalculatordlg.h(160) : see declaration of 'SetEditRead'
C:\Program Files\Microsoft Visual Studio\MyProjects\GPACalculator\GPACalculatorDlg.cpp(298) : error C2509: 'OnCtlColor' : member function not declared in 'CGPACalculatorDlg'
        c:\program files\microsoft visual studio\myprojects\gpacalculator\gpacalculatordlg.h(14) : see declaration of 'CGPACalculatorDlg'
Generating Code...
Error executing cl.exe.

GPACalculator.exe - 11 error(s), 0 warning(s)
好好学习,天天向上。
2楼2011-05-07 20:52:49
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖

yalefield

金虫 (文坛精英)

老汉一枚

【答案】应助回帖

zyj8119(金币+20): 感谢老汉一语惊醒梦中人。。。。 2011-05-08 11:42:05
在GPACalculatorDlg.h中,
CODE:
        double GetSDPoint(double dPoint);

        double CGPACalculatorDlg::GetSDPoint(double dPoint)
        {
                UpdateData();
                ....
        }

您既声明了函数,随即又给出函数的实现,不仅很啰嗦,而且使得编译器都嫌您啰嗦。
3楼2011-05-08 09:34:34
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖
相关版块跳转 我要订阅楼主 zyj8119 的主题更新
最具人气热帖推荐 [查看全部] 作者 回/看 最后发表
[基金申请] 欢迎发来filecode的Mz6后的代码验证其规律 +3 医学老男孩 2026-08-13 6/300 2026-08-13 14:38 by 超级海虾
[基金申请] 不应该看fileCode +7 且听虎啸 2026-08-12 9/450 2026-08-13 14:27 by flydreamws
[基金申请] FileCode能看出啥? +8 要乐观耀哥 2026-08-10 26/1300 2026-08-13 12:01 by Tide man
[基金申请] 关于Filecode分析方法 +9 majunge000 2026-08-10 11/550 2026-08-13 10:40 by ZH远山
[基金申请] 重要来源:本周末出结果 +9 瞬息宇宙 2026-08-12 9/450 2026-08-13 10:12 by Vivilian
[基金申请] 应该是93bebmhtak前后十一个字符比较关键 +22 Lanmanbaby 2026-08-09 36/1800 2026-08-12 22:50 by sdfapple719
[基金申请] filecode +13 documentary 2026-08-10 15/750 2026-08-12 15:56 by 云上清扬
[论文投稿] 职称评审,求友友推荐见刊最快的期刊 +4 工厂打螺丝 2026-08-08 4/200 2026-08-12 09:18 by hansi2025
[基金申请] 奇怪,两个人的filecode固定段从头到尾一模一样 +7 布布和一二 2026-08-10 10/500 2026-08-12 09:12 by 布布和一二
[基金申请] 是这周出结果还是下周出结果? +3 yuleib84 2026-08-11 3/150 2026-08-11 21:53 by jnhyjjm
[硕博家园] 读博的好处 +3 lnee 2026-08-11 3/150 2026-08-11 18:10 by 希望我好好的
[基金申请] 什么时候出结果,有咨询渠道??? +3 Tide man 2026-08-11 3/150 2026-08-11 17:54 by kudofaye
[基金申请] 关于代码变化问题,想知道的进来 +17 且听虎啸 2026-08-07 24/1200 2026-08-10 18:35 by zhangduo2008
[基金申请] 国自然结果 +4 Vierhys 2026-08-10 8/400 2026-08-10 15:06 by Vierhys
[基金申请] 据悉今年马上要出结果了 +7 瞬息宇宙 2026-08-10 8/400 2026-08-10 12:42 by Vivilian
[基金申请] 这样的filecode谁见过 +11 布布和一二 2026-08-08 22/1100 2026-08-10 11:10 by wmfsnow
[基金申请] 关于filecode,很负责任的告诉大家 +6 爱看书的可乐 2026-08-08 7/350 2026-08-08 22:13 by a_niu
[基金申请] 关于filecode +4 布布和一二 2026-08-07 7/350 2026-08-07 22:55 by zhanghaozhu
[基金申请] 固定端突然变了,今天 +6 archvillain 2026-08-06 10/500 2026-08-07 16:03 by 医学老男孩
[基金申请] filecode变化情况 +6 布布和一二 2026-08-07 22/1100 2026-08-07 14:45 by 且听虎啸
信息提示
请填处理意见