資源簡介
本書從初學者的角度講述C++語言學習應該掌握的各項基礎(chǔ),突出“基礎(chǔ)”和“全面”,書中例子的源碼也很清晰易懂,請一起學習進步!
代碼片段和文件信息
//?Hello.cpp?:?Defines?the?class?behaviors?for?the?application.
//
#include?“stdafx.h“
#include?“Hello.h“
#include?“HelloDlg.h“
#ifdef?_DEBUG
#define?new?DEBUG_NEW
#undef?THIS_FILE
static?char?THIS_FILE[]?=?__FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
//?CHelloApp
BEGIN_MESSAGE_MAP(CHelloApp?CWinApp)
//{{AFX_MSG_MAP(CHelloApp)
//?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()
/////////////////////////////////////////////////////////////////////////////
//?CHelloApp?construction
CHelloApp::CHelloApp()
{
//?TODO:?add?construction?code?here
//?Place?all?significant?initialization?in?InitInstance
}
/////////////////////////////////////////////////////////////////////////////
//?The?one?and?only?CHelloApp?object
CHelloApp?theApp;
/////////////////////////////////////////////////////////////////////////////
//?CHelloApp?initialization
BOOL?CHelloApp::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
CHelloDlg?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;
}
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????文件?????106574??2011-09-08?11:11??Instances\1\例1.1\Hello\Debug\Hello.exe
?????文件?????190152??2011-09-08?11:11??Instances\1\例1.1\Hello\Debug\Hello.ilk
?????文件??????14258??2011-09-08?11:10??Instances\1\例1.1\Hello\Debug\Hello.obj
?????文件????5505248??2011-09-08?11:10??Instances\1\例1.1\Hello\Debug\Hello.pch
?????文件?????271360??2011-09-08?11:11??Instances\1\例1.1\Hello\Debug\Hello.pdb
?????文件???????2660??2011-09-08?11:10??Instances\1\例1.1\Hello\Debug\Hello.res
?????文件??????27122??2011-09-08?11:10??Instances\1\例1.1\Hello\Debug\HelloDlg.obj
?????文件?????105700??2011-09-08?11:10??Instances\1\例1.1\Hello\Debug\StdAfx.obj
?????文件?????205824??2011-09-08?11:11??Instances\1\例1.1\Hello\Debug\vc60.idb
?????文件?????364544??2011-09-08?11:10??Instances\1\例1.1\Hello\Debug\vc60.pdb
?????文件??????21028??2011-09-08?11:10??Instances\1\例1.1\Hello\Hello.aps
?????文件???????1278??2011-09-08?11:11??Instances\1\例1.1\Hello\Hello.clw
?????文件???????2049??2009-05-13?12:54??Instances\1\例1.1\Hello\Hello.cpp
?????文件???????4141??2009-05-13?12:54??Instances\1\例1.1\Hello\Hello.dsp
?????文件????????535??2009-05-13?12:54??Instances\1\例1.1\Hello\Hello.dsw
?????文件???????1313??2009-05-13?12:54??Instances\1\例1.1\Hello\Hello.h
?????文件??????41984??2011-09-08?11:11??Instances\1\例1.1\Hello\Hello.ncb
?????文件??????53760??2011-09-08?11:11??Instances\1\例1.1\Hello\Hello.opt
?????文件???????1634??2011-09-08?11:11??Instances\1\例1.1\Hello\Hello.plg
?????文件???????5498??2009-05-13?12:57??Instances\1\例1.1\Hello\Hello.rc
?????文件???????4717??2009-05-13?12:57??Instances\1\例1.1\Hello\HelloDlg.cpp
?????文件???????1358??2009-05-13?12:57??Instances\1\例1.1\Hello\HelloDlg.h
?????文件???????3561??2009-05-13?12:54??Instances\1\例1.1\Hello\ReadMe.txt
?????文件???????1078??2009-05-13?12:54??Instances\1\例1.1\Hello\res\Hello.ico
?????文件????????397??2009-05-13?12:54??Instances\1\例1.1\Hello\res\Hello.rc2
?????文件????????775??2009-05-13?12:57??Instances\1\例1.1\Hello\resource.h
?????文件????????207??2009-05-13?12:54??Instances\1\例1.1\Hello\StdAfx.cpp
?????文件???????1054??2009-05-13?12:54??Instances\1\例1.1\Hello\StdAfx.h
?????文件???????3705??2009-04-17?08:52??Instances\10\例10.1\SimpleTextOut\ReadMe.txt
?????文件???????1078??2009-04-17?08:52??Instances\10\例10.1\SimpleTextOut\res\SimpleTextOut.ico
............此處省略4236個文件信息
評論
共有 條評論