selectdialog.cpp
来自「VC6开发的用于进行色谱分析的示例」· C++ 代码 · 共 92 行
CPP
92 行
// selectDialog.cpp : implementation file
//
#include "stdafx.h"
#include "MyWork.h"
#include "selectDialog.h"
#include "table1Dialog.h"
#include "table2Dialog.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
// CselectDialog dialog
CselectDialog::CselectDialog(CWnd* pParent /*=NULL*/)
: CDialog(CselectDialog::IDD, pParent)
{
//{{AFX_DATA_INIT(CselectDialog)
//}}AFX_DATA_INIT
}
void CselectDialog::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
//{{AFX_DATA_MAP(CselectDialog)
//}}AFX_DATA_MAP
}
BEGIN_MESSAGE_MAP(CselectDialog, CDialog)
//{{AFX_MSG_MAP(CselectDialog)
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// CselectDialog message handlers
void CselectDialog::OnOK()
{
// TODO: Add extra validation here
/* int i;
i=m_kubiao.GetCurSel();
if (i==1)
{
Ctable1Dialog dlg;
dlg.DoModal();
}
else
{
if (i==0)
{
Ctable2Dialog dlg;
dlg.DoModal();
}
else
{
MessageBox("你没有选择正确的数据表!","警告!",MB_ICONINFORMATION);
CselectDialog dlg;
dlg.DoModal();
}
} */
UINT nradio=GetCheckedRadioButton(IDC_RADIO_ATTRI,IDC_RADIO_SEPU);
//判断选择了什么运算符
switch (nradio)
{
case IDC_RADIO_ATTRI:
{
Ctable1Dialog dlg;
dlg.DoModal();
break;
}
case IDC_RADIO_SEPU:
{
Ctable2Dialog dlg;
dlg.DoModal();
break;
}
default:
{
MessageBox("你没有选择要查询的中药材信息!","警告!",MB_ICONINFORMATION);
break;
}
}
CDialog::OnOK();
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?