1。完成一个小程序后编译出现Cannot open precompiled header file: 'Debug/caculate.pch': No such file or directory
是怎摸回事啊???
2。 用什么函数能将Edit控件中的内容取出负给一个String变量???

解决方案 »

  1.   

    去看一下FAQ“编程经验总结” 有很多贴子都是此类问题
      

  2.   

    1.有可能是你刚才打开了Debug里的.exe文件,即程序窗口正显示中,所以不能找到!
    把你 的程序窗口关了,再编译看看!
    2.用GetWindowText() 函数即可,其具体形式如下:
    CString str;
    pEdit->GetWindowText(str);//pEdit为你定义的Edit控件的指针
      

  3.   

    我用向导定义了控件变量m_edit1
    可以写成m_edit1.GetwindowText(str)吗?
    怎样定义控件指针啊?
      

  4.   

    http://expert.csdn.net/Expert/topic/2398/2398212.xml?temp=.9919092
    你可以那样得到控件的窗口标题。定义控件指针就是控件类型为指针类型。如控件类型为 CEdit.给他定义一个指针类型变量为:CEdit *m_edit;
      

  5.   

    怎样定义控件指针啊?---CEdit* pEdit = ...完成一个小程序后编译出现Cannot open precompiled header file: 'Debug/caculate.pch': No such file or directory
    是怎摸回事啊???
    ---把debug目录下面的文件,全删掉即可。或者,build->Rebuild All都行 用什么函数能将Edit控件中的内容取出负给一个String变量???
    ---注意你的UpdateData函数是否用了?