vC++unexpected end of file found
vC++unexpected end of file foundvoid CCalculator2Dlg::OnOffButton() { CString initialCaption, newCaption; GetDlgItemText(IDC_OFF_BUTTON, initialCaption); if (initialCaption == "&Power Off") { newCaption = "&Power On"; // -- hide all the controls // -- CButton objects //CButton *pButton = (CButton*) GetDlgItem(IDC_ADD_BUTTON); //pButton ->ShowWindow(FALSE); GetDlgItem(IDC_ADD_BUTTON)->ShowWindow(FALSE); CButton *pButton; pButton = (CButton*) GetDlgItem(IDC_SUB_BUTTON); pButton ->ShowWindow(FALSE); pButton = (CButton*) GetDlgItem(IDC_MUL_BUTTON); pButton ->ShowWindow(FALSE); pButton = (CButton*) GetDlgItem(IDC_DIV_BUTTON); pButton ->ShowWindow(FALSE); pButton = (CButton*) GetDlgItem(IDC_TOGGLE_BUTTON); pButton ->ShowWindow(FALSE); // -- CEdit objects CEdit *pEdit = (CEdit*) GetDlgItem(IDC_NUM1_EDIT); pEdit ->ShowWindow(FALSE); pEdit = (CEdit*) GetDlgItem(IDC_NUM2_EDIT); pEdit ->ShowWindow(FALSE); pEdit = (CEdit*) GetDlgItem(IDC_RESULT_EDIT); pEdit ->ShowWindow(FALSE); // -- CScrollBar objects CScrollBar *pSB = (CScrollBar*) GetDlgItem(IDC_NUM1_SCROLLBAR); pSB ->ShowWindow(FALSE); pSB = (CScrollBar*) GetDlgItem(IDC_NUM2_SCROLLBAR); pSB ->ShowWindow(FALSE); } else { newCaption = "&Power Off"; // -- show all the controls // -- CButton objects CButton *pButton = (CButton*) GetDlgItem(IDC_ADD_BUTTON); pButton ->ShowWindow(TRUE); pButton = (CButton*) GetDlgItem(IDC_SUB_BUTTON); pButton ->ShowWindow(TRUE); pButton = (CButton*) GetDlgItem(IDC_MUL_BUTTON); pButton ->ShowWindow(TRUE); pButton = (CButton*) GetDlgItem(IDC_DIV_BUTTON); pButton ->ShowWindow(TRUE); pButton = (CButton*) GetDlgItem(IDC_TOGGLE_BUTTON); pButton ->ShowWindow(TRUE); // -- CEdit objects CEdit *pEdit = (CEdit*) GetDlgItem(IDC_NUM1_EDIT); pEdit ->ShowWindow(TRUE); pEdit = (CEdit*) GetDlgItem(IDC_NUM2_EDIT); pEdit ->ShowWindow(TRUE); pEdit = (CEdit*) GetDlgItem(IDC_RESULT_EDIT); pEdit ->ShowWindow(TRUE); // -- CScrollBar objects CScrollBar *pSB = (CScrollBar*) GetDlgItem(IDC_NUM1_SCROLLBAR); pSB ->ShowWindow(TRUE); pSB = (CScrollBar*) GetDlgItem(IDC_NUM2_SCROLLBAR); pSB ->ShowWindow(TRUE); } // -- update the caption of the power button SetDlgItemText(IDC_OFF_BUTTON, newCaption); // -- reset the diolog box to its initial state OnInitDialog(); return;}在MICRO VS2005没问题,但到VC6.0就不行了,这个CODE是VC6.0的其实.fatal error C1004: unexpected end of file foundError executing cl.exe.还有这个问题.好奇怪啊.程序在VS2005都没问题.而且这些CODE都是VC++的
最佳回答
vc6。0和vs2005并不完全一样,你看看return或是}吧。
最新回答共有2条回答
-
2026-04-01 06:53:50忐忑的翅膀
回复vc6。0和vs2005并不完全一样,你看看return或是}吧。
热门文章
- 康达学院专转本五年制
- 高考一个考场分ab卷吗
- not only but also用法
- 某物体做自由落体运动,从释放开始计时,则物体在前2s内的平均速度为______m/s,物体下落2m时的速度大小为______m/s.
- 三角函数公式大全表格
- 地理中考必背知识点2022
- 2013-2014学年小学六年级科学上学期期末考试试卷及答案
- 人教版2014-2015学年小学五年级英语第二学期期中教学质量检测试卷及答案
- 【Linux驱动开发】设备树详解(二)设备树语法详解
- 别跟客户扯细节
- 在别的城市买房子能落户吗
- 卖房前要把装修贷还完吗
- 高中政治教学提高教学效果的方法探究
- “互联网+”背景下的初中英语课堂教学改革与创新策略研究
- 2022年终止合同范本
- 租房合同范本范文
- 如何挑选土豆
- 如何挑选土鸡
