刘华世的官方博客
摘要: BOOL CWelcomeDlg::PreTranslateMessage(MSG* pMsg) //Called to filter messages before they are dispatched{ // TODO: Add your specialized code here and/or call the base class if(pMsg->message == WM_KEYDOWN && pMsg->wParam == 27) { CString s; s.Format("The wParam= %d The message =... 阅读全文
posted @ 2012-11-15 10:41 pythonschool 阅读(356) 评论(0) 推荐(0) 编辑
摘要: BOOL CBeginDlg::OnInitDialog(){ SetTimer(1, 100, NULL); //触发定时器}void CBeginDlg::OnTimer(UINT_PTR nIDEvent){ // TODO: 在此添加消息处理程序代码和/或调用默认值 //MessageBox(L"hello"); CRect rc; CRect rect; GetWindowRect(&rect); rc.CopyRect(&rect); CPoint pOint; GetCursorPos(&pOint); CString ... 阅读全文
posted @ 2012-11-15 10:41 pythonschool 阅读(276) 评论(0) 推荐(0) 编辑
摘要: Login dlg; if(dlg.DoModal()!=IDOK) { OnOK(); }void Login::OnOK() { // TODO: Add extra validation here //CEdit *pEdit1 = (CEdit *)GetDlgItem(IDC_EDIT1); //CEdit *pEdit2 = (CEdit *)GetDlgItem(IDC_EDIT2); //CString e1, e2; //pEdit1->GetWindowText(e1); //pEdit2->Get... 阅读全文
posted @ 2012-11-15 10:41 pythonschool 阅读(1273) 评论(0) 推荐(0) 编辑
摘要: void CWelcomeDlg::OnClose() { // TODO: Add your message handler code here and/or call default if(MessageBox("Are you sure close this windows?", "closing", MB_OKCANCEL|MB_ICONQUESTION) == IDOK) { CDialog::OnClose(); } //创建一个基于对话框的应用程序. //通过类向导选择WM_CLOSE消息事件 //在对话框的消息事件... 阅读全文
posted @ 2012-11-15 10:41 pythonschool 阅读(2966) 评论(0) 推荐(0) 编辑
刘华世的官方博客