資源簡介
winsock 文件傳輸 多線程
很水的一個實驗,傳上來大家看看,也許有幫助

代碼片段和文件信息
//?Client.cpp?:?Defines?the?class?behaviors?for?the?application.
//
#include?“stdafx.h“
#include?“Client.h“
#include?“ClientDlg.h“
#ifdef?_DEBUG
#define?new?DEBUG_NEW
#undef?THIS_FILE
static?char?THIS_FILE[]?=?__FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
//?CClientApp
BEGIN_MESSAGE_MAP(CClientApp?CWinApp)
//{{AFX_MSG_MAP(CClientApp)
//?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()
/////////////////////////////////////////////////////////////////////////////
//?CClientApp?construction
CClientApp::CClientApp()
{
//?TODO:?add?construction?code?here
//?Place?all?significant?initialization?in?InitInstance
}
/////////////////////////////////////////////////////////////////////////////
//?The?one?and?only?CClientApp?object
CClientApp?theApp;
/////////////////////////////////////////////////////////////////////////////
//?CClientApp?initialization
BOOL?CClientApp::InitInstance()
{
if?(!AfxSocketInit())
{
AfxMessageBox(IDP_SOCKETS_INIT_FAILED);
return?FALSE;
}
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
CClientDlg?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;
}
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????目錄???????????0??2010-07-10?18:21??文件傳輸winsock\
?????目錄???????????0??2010-05-07?12:41??文件傳輸winsock\Client\
?????文件???????21644??2010-04-25?14:32??文件傳輸winsock\Client\Client.aps
?????文件????????1211??2010-04-25?14:36??文件傳輸winsock\Client\Client.clw
?????文件????????2157??2009-12-21?08:51??文件傳輸winsock\Client\Client.cpp
?????文件????????4055??2009-12-21?08:51??文件傳輸winsock\Client\Client.dsp
?????文件?????????518??2009-12-21?12:39??文件傳輸winsock\Client\Client.dsw
?????文件????????1324??2009-12-21?08:51??文件傳輸winsock\Client\Client.h
?????文件???????74752??2010-04-25?14:37??文件傳輸winsock\Client\Client.ncb
?????文件???????53760??2010-04-25?14:37??文件傳輸winsock\Client\Client.opt
?????文件?????????246??2009-12-21?14:13??文件傳輸winsock\Client\Client.plg
?????文件????????5495??2009-12-21?10:35??文件傳輸winsock\Client\Client.rc
?????文件????????9567??2009-12-21?14:08??文件傳輸winsock\Client\ClientDlg.cpp
?????文件????????1736??2009-12-21?10:05??文件傳輸winsock\Client\ClientDlg.h
?????目錄???????????0??2010-05-07?12:41??文件傳輸winsock\Client\Debug\
?????文件?????2142259??2009-12-21?14:08??文件傳輸winsock\Client\Debug\Client.exe
?????文件????????3579??2009-12-21?08:51??文件傳輸winsock\Client\ReadMe.txt
?????目錄???????????0??2010-05-07?12:41??文件傳輸winsock\Client\res\
?????文件?????????913??2009-12-21?08:54??文件傳輸winsock\Client\resource.h
?????文件????????1078??2009-12-21?08:51??文件傳輸winsock\Client\res\Client.ico
?????文件?????????398??2009-12-21?08:51??文件傳輸winsock\Client\res\Client.rc2
?????文件?????????208??2009-12-21?08:51??文件傳輸winsock\Client\StdAfx.cpp
?????文件????????1102??2009-12-21?08:51??文件傳輸winsock\Client\StdAfx.h
?????文件??????????74??2009-12-21?14:09??文件傳輸winsock\Client\新建文本文檔.txt
?????目錄???????????0??2010-05-07?12:41??文件傳輸winsock\Server\
?????文件???????????0??2009-12-21?11:40??文件傳輸winsock\Server\123.txt
?????文件????????1211??2009-12-21?14:10??文件傳輸winsock\Server\Client.clw
?????目錄???????????0??2010-05-07?12:41??文件傳輸winsock\Server\Debug\
?????文件?????2158643??2009-12-21?14:13??文件傳輸winsock\Server\Debug\Server.exe
?????文件????????3579??2009-12-21?07:52??文件傳輸winsock\Server\ReadMe.txt
?????目錄???????????0??2010-05-07?12:41??文件傳輸winsock\Server\res\
............此處省略19個文件信息
評論
共有 條評論