資源簡介
MFC中將CScrollView視圖顯示在對話框中,在對話框中實現(xiàn)文檔視圖結構。

代碼片段和文件信息
//?DialogView.cpp?:?Defines?the?class?behaviors?for?the?application.
//
#include?“stdafx.h“
#include?“DialogView.h“
#include?“DialogViewDlg.h“
#ifdef?_DEBUG
#define?new?DEBUG_NEW
#undef?THIS_FILE
static?char?THIS_FILE[]?=?__FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
//?CDialogViewApp
BEGIN_MESSAGE_MAP(CDialogViewApp?CWinApp)
//{{AFX_MSG_MAP(CDialogViewApp)
//?NOTE?-?the?ClassWizard?will?add?and?remove?mapping?macros?here.
//????DO?NOT?EDIT?what?you?see?in?these?blocks?of?generated?code!
//}}AFX_MSG
ON_COMMAND(ID_HELP?CWinApp::onhelp)
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
//?CDialogViewApp?construction
CDialogViewApp::CDialogViewApp()
{
//?TODO:?add?construction?code?here
//?Place?all?significant?initialization?in?InitInstance
}
/////////////////////////////////////////////////////////////////////////////
//?The?one?and?only?CDialogViewApp?object
CDialogViewApp?theApp;
/////////////////////////////////////////////////////////////////////////////
//?CDialogViewApp?initialization
BOOL?CDialogViewApp::InitInstance()
{
AfxEnableControlContainer();
//?Standard?initialization
//?If?you?are?not?using?these?features?and?wish?to?reduce?the?size
//??of?your?final?executable?you?should?remove?from?the?following
//??the?specific?initialization?routines?you?do?not?need.
#ifdef?_AFXDLL
Enable3dControls(); //?Call?this?when?using?MFC?in?a?shared?DLL
#else
Enable3dControlsStatic(); //?Call?this?when?linking?to?MFC?statically
#endif
CDialogViewDlg?dlg;
m_pMainWnd?=?&dlg;
int?nResponse?=?dlg.DoModal();
if?(nResponse?==?IDOK)
{
//?TODO:?Place?code?here?to?handle?when?the?dialog?is
//??dismissed?with?OK
}
else?if?(nResponse?==?IDCANCEL)
{
//?TODO:?Place?code?here?to?handle?when?the?dialog?is
//??dismissed?with?Cancel
}
//?Since?the?dialog?has?been?closed?return?FALSE?so?that?we?exit?the
//??application?rather?than?start?the?application‘s?message?pump.
return?FALSE;
}
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????文件?????239500??2008-09-07?11:24??DialogView\DialogView.aps
?????文件???????1340??2008-09-07?11:30??DialogView\DialogView.clw
?????文件???????2119??2008-09-07?10:08??DialogView\DialogView.cpp
?????文件???????4564??2008-09-07?11:30??DialogView\DialogView.dsp
?????文件????????543??2008-09-07?10:08??DialogView\DialogView.dsw
?????文件???????1368??2008-09-07?10:08??DialogView\DialogView.h
?????文件??????50176??2008-09-07?11:30??DialogView\DialogView.ncb
?????文件??????49664??2008-09-07?11:30??DialogView\DialogView.opt
?????文件???????1400??2008-09-07?11:29??DialogView\DialogView.plg
?????文件???????5409??2008-09-07?11:24??DialogView\DialogView.rc
?????文件???????4951??2008-09-07?11:09??DialogView\DialogViewDlg.cpp
?????文件???????1386??2008-09-07?10:08??DialogView\DialogViewDlg.h
?????文件???????1426??2008-09-07?10:11??DialogView\DlgDocument.cpp
?????文件???????1483??2008-09-07?10:41??DialogView\DlgDocument.h
?????文件???????1888??2008-09-07?11:29??DialogView\DlgView.cpp
?????文件???????1508??2008-09-07?10:41??DialogView\DlgView.h
?????文件???????1406??2002-01-10?20:39??DialogView\MyDocument.cpp
?????文件???????1442??2002-01-10?20:57??DialogView\MyDocument.h
?????文件???????3651??2008-09-07?10:08??DialogView\ReadMe.txt
?????文件???????1078??2008-09-07?10:08??DialogView\res\DialogView.ico
?????文件????????402??2008-09-07?10:08??DialogView\res\DialogView.rc2
????..A.SH.??????4608??2008-09-07?11:30??DialogView\res\Thumbs.db
?????文件?????203830??2008-09-07?11:24??DialogView\res\未命名.bmp
?????文件????????687??2008-09-07?11:24??DialogView\resource.h
?????文件????????212??2008-09-07?10:08??DialogView\StdAfx.cpp
?????文件???????1054??2008-09-07?10:08??DialogView\StdAfx.h
?????目錄??????????0??2008-09-07?11:30??DialogView\Debug
?????目錄??????????0??2008-09-07?11:30??DialogView\Release
?????目錄??????????0??2008-09-07?11:24??DialogView\res
?????目錄??????????0??2008-09-07?11:30??DialogView
............此處省略3個文件信息
評論
共有 條評論