📄 griddlghygl.cpp
字号:
// GridDLGHYGL.cpp : implementation file
//
#include "stdafx.h"
#include "test2.h"
#include "GridDLGHYGL.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
// CGridDLGHYGL dialog
CGridDLGHYGL::CGridDLGHYGL(CWnd* pParent /*=NULL*/)
: CDialog(CGridDLGHYGL::IDD, pParent)
{
//{{AFX_DATA_INIT(CGridDLGHYGL)
// NOTE: the ClassWizard will add member initialization here
//}}AFX_DATA_INIT
}
void CGridDLGHYGL::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
//{{AFX_DATA_MAP(CGridDLGHYGL)
DDX_Control(pDX, IDC_DATAGRID, m_wndGrid);
// NOTE: the ClassWizard will add DDX and DDV calls here
//}}AFX_DATA_MAP
}
BEGIN_MESSAGE_MAP(CGridDLGHYGL, CDialog)
//{{AFX_MSG_MAP(CGridDLGHYGL)
// NOTE: the ClassWizard will add message map macros here
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// CGridDLGHYGL message handlers
BOOL CGridDLGHYGL::OnInitDialog()
{
CDialog::OnInitDialog();
m_wndGrid.SetCaption("MyADO");//打算将此赋给一变量c_Title
m_wndGrid.SetRefDataSource(NULL);
m_wndGrid.SetRefDataSource((LPUNKNOWN)m_adoRecordSet->GetRecordset());//根据需要显示
m_wndGrid.SetAllowAddNew(TRUE);
m_wndGrid.SetAllowDelete(TRUE);
m_wndGrid.SetAllowUpdate(TRUE);
m_wndGrid.Refresh();
return TRUE; // return TRUE unless you set the focus to a control
// EXCEPTION: OCX Property Pages should return FALSE
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -