caiyang.cpp

来自「这是一个水箱的液位控制程序」· C++ 代码 · 共 83 行

CPP
83
字号
// caiyang.cpp : implementation file//#include "stdafx.h"#include "水箱实验.h"#include "caiyang.h"#include "conio.h"#ifdef _DEBUG#define new DEBUG_NEW#undef THIS_FILEstatic char THIS_FILE[] = __FILE__;#endif/////////////////////////////////////////////////////////////////////////////// Ccaiyang dialogCcaiyang::Ccaiyang(CWnd* pParent /*=NULL*/)	: CDialog(Ccaiyang::IDD, pParent){		//{{AFX_DATA_INIT(Ccaiyang)	m_time = 0;	//}}AFX_DATA_INIT}void Ccaiyang::DoDataExchange(CDataExchange* pDX){	CDialog::DoDataExchange(pDX);	//{{AFX_DATA_MAP(Ccaiyang)	DDX_Text(pDX, IDC_EDIT2, m_time);	//}}AFX_DATA_MAP}BEGIN_MESSAGE_MAP(Ccaiyang, CDialog)	//{{AFX_MSG_MAP(Ccaiyang)	ON_EN_CHANGE(IDC_EDIT2, OnChangeEdit2)	ON_WM_PAINT()	//}}AFX_MSG_MAPEND_MESSAGE_MAP()/////////////////////////////////////////////////////////////////////////////// Ccaiyang message handlersvoid Ccaiyang::OnChangeEdit2() {	// TODO: If this is a RICHEDIT control, the control will not	// send this notification unless you override the CDialog::OnInitDialog()	// function and call CRichEditCtrl().SetEventMask()	// with the ENM_CHANGE flag ORed into the mask.		// TODO: Add your control notification handler code here	}BOOL Ccaiyang::OnInitDialog() {	CDialog::OnInitDialog();		// TODO: Add extra initialization here		return TRUE;  // return TRUE unless you set the focus to a control	              // EXCEPTION: OCX Property Pages should return FALSE}void Ccaiyang::OnPaint() {	CPaintDC dc(this); // device context for painting		// TODO: Add your message handler code here	HWND edit;	GetDlgItem(IDC_EDIT2,&edit);	::SetFocus(edit);		// Do not call CDialog::OnPaint() for painting messages}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?