ftpsite.cpp

来自「Transfer Files to and from an FTP Server」· C++ 代码 · 共 58 行

CPP
58
字号
// FTPSite.cpp : implementation file
//

#include "stdafx.h"
#include "FTP.h"
#include "FTPSite.h"

#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif

extern char UserName[], SiteName[], Password[];
/////////////////////////////////////////////////////////////////////////////
// CFTPSite dialog


CFTPSite::CFTPSite(CWnd* pParent /*=NULL*/)
	: CDialog(CFTPSite::IDD, pParent)
{
	//{{AFX_DATA_INIT(CFTPSite)
	m_Pass = _T("");
	m_Site = _T("");
	m_User = _T("");
	//}}AFX_DATA_INIT
}


void CFTPSite::DoDataExchange(CDataExchange* pDX)
{
	CDialog::DoDataExchange(pDX);
	//{{AFX_DATA_MAP(CFTPSite)
	DDX_Text(pDX, IDC_PASS, m_Pass);
	DDX_Text(pDX, IDC_SITE, m_Site);
	DDX_Text(pDX, IDC_USER, m_User);
	//}}AFX_DATA_MAP
}


BEGIN_MESSAGE_MAP(CFTPSite, CDialog)
	//{{AFX_MSG_MAP(CFTPSite)
	//}}AFX_MSG_MAP
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// CFTPSite message handlers

void CFTPSite::OnOK() 
{
	// TODO: Add extra validation here
	UpdateData(TRUE);
	strcpy(SiteName, (LPSTR)(LPCTSTR)m_Site);	
	strcpy(UserName, (LPSTR)(LPCTSTR)m_User);	
	strcpy(Password, (LPSTR)(LPCTSTR)m_Pass);	
	CDialog::OnOK();
}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?