我来我网
https://5come5.cn
 
您尚未 登录  注册 | 菠菜 | 软件站 | 音乐站 | 邮箱1 | 邮箱2 | 风格选择 | 更多 » 
 

本页主题: [求助]蝈蝈们来看看一个简单的MFC程序 显示签名 | 打印 | 加为IE收藏 | 收藏主题 | 上一主题 | 下一主题

ppt……



性别: 保密 状态: 该用户目前不在线
等级: 品行端正
家族: ★课件天地★
发贴: 169
威望: 0
浮云: 1172
在线等级:
注册时间: 2006-06-27
最后登陆: 2007-04-01

5come5帮你背单词 [ defendant /di'fendənt/ n. & a. 被告人(的) ]


[求助]蝈蝈们来看看一个简单的MFC程序

rt
一个简单的MFC程序
#include "afxwin.h"
class CMyApp:public CWinApp
{
public:
   virtual BOOL InitInstance();
   //rewrite the initinstance function in myapp
};
class CMainWnd:public CFrameWnd
{
protected:
   afx_msg void Function1(WPARAM wParam,LPARAM lParam)
       //function to deal with the information
   {
       MessageBox("左键单击");
   }
  afx_msg void Function1(WPARAM wParam,LPARAM lParam)
       //function to deal with the information
   {
       MessageBox("右键单击");
   }
DECLARE_MESSAGE_MAP();
};
BEGIN_MESSAGE_MAP(CMainWnd,CFrameWnd);
ON_MESSAGE(WM_LBUTTONDOWN,Function1);
ON_MESSAGE(WM_LBUTTONDOWN,Function1);
END_MESSAGE_MAP();
BOOL CMyApp::InitInstance()
{
   CFrameWnd*p=new CFrameWnd; //produce the win class
p->Create(0,"workspace");       //create the window
p->ShowWindow(SW_SHOWMAXIMIZED);//show the window
p->UpdateWindow();
AfxGetApp()->m_pMainWnd=p;     //focus on the mainwindow
return TRUE;
}
CMyApp myapp;

编译的时候出现的错误是
fatal error C1010: unexpected end of file while looking for precompiled header directive

蝈蝈们帮忙给找找原因吧
顶端 Posted: 2006-10-14 16:34 | [楼 主]
hhbhhb



性别: 帅哥 状态: 该用户目前不在线
等级: 品行端正
发贴: 292
威望: 0
浮云: 1105
在线等级:
注册时间: 2006-09-21
最后登陆: 2009-03-16

5come5帮你背单词 [ range /reind3ə/ n. 范围,领域,(山)脉;vt. 排列成行,把…分类;vi. 列成一行,并列,延伸,变化 ]


include一下stdafx.h……
或者好像可以在项目里关掉预编译头。。
顶端 Posted: 2006-10-14 16:57 | [1 楼]
我来我网·5come5 Forum » 程序员之家

Total 0.007314(s) query 6, Time now is:06-26 18:21, Gzip enabled
Powered by PHPWind v5.3, Localized by 5come5 Tech Team, 黔ICP备16009856号