query.cpp
资源名称:一个学生管理系统.rar [点击查看]
上传用户:hzzhuce
上传日期:2013-04-01
资源大小:1289k
文件大小:2k
源码类别:
SQL Server
开发平台:
Visual C++
- // query.cpp : implementation file
- //
- #include "stdafx.h"
- #include "student.h"
- #include "query.h"
- #ifdef _DEBUG
- #define new DEBUG_NEW
- #undef THIS_FILE
- static char THIS_FILE[] = __FILE__;
- #endif
- /////////////////////////////////////////////////////////////////////////////
- // Cquery dialog
- Cquery::Cquery(CWnd* pParent /*=NULL*/)
- : CDialog(Cquery::IDD, pParent)
- {
- //{{AFX_DATA_INIT(Cquery)
- m_find = _T("");
- //}}AFX_DATA_INIT
- }
- void Cquery::DoDataExchange(CDataExchange* pDX)
- {
- CDialog::DoDataExchange(pDX);
- //{{AFX_DATA_MAP(Cquery)
- DDX_Control(pDX, IDC_COMBO3, m_select);
- DDX_Control(pDX, IDC_COMBO2, m_query);
- DDX_Text(pDX, IDC_EDIT1, m_find);
- //}}AFX_DATA_MAP
- }
- BEGIN_MESSAGE_MAP(Cquery, CDialog)
- //{{AFX_MSG_MAP(Cquery)
- ON_WM_CANCELMODE()
- //}}AFX_MSG_MAP
- END_MESSAGE_MAP()
- /////////////////////////////////////////////////////////////////////////////
- // Cquery message handlers
- void Cquery::OnOK()
- {
- // TODO: Add extra validation here
- UpdateData(TRUE);
- m_query.GetLBText(m_query.GetCurSel(),m_Getstring1);
- m_select.GetLBText(m_select.GetCurSel(),m_Getstring2);
- CDialog::OnOK();
- }
- BOOL Cquery::OnInitDialog()
- {
- CDialog::OnInitDialog();
- // TODO: Add extra initialization here
- m_query.SetCurSel(1);
- m_select.SetCurSel(2);
- return TRUE; // return TRUE unless you set the focus to a control
- // EXCEPTION: OCX Property Pages should return FALSE
- }
- void Cquery::OnCancelMode()
- {
- CDialog::OnCancelMode();
- // TODO: Add your message handler code here
- }