bool GetFile( CString strLocalFile, CString strServerFile )
{
// 建立连接
CInternetSession m_isSession;
CFtpConnection *m_ftpConn = m_isSession.GetFtpConnection( FtpServer, FtpUser, FtpPass, 0, TRUE );

// 下传文件
int iRC = m_ftpConn->GetFile( strServerFile, strLocalFile, FALSE ); CString strDirName ; bool brc = m_ftpConn->GetCurrentDirectory( strDirName );
iRC = m_ftpConn->Remove( strServerFile ); // 关闭连接
m_ftpConn->Close();
m_isSession.Close(); if( iRC == 0 )
{
// 下传失败
DWORD   dwErr   =   GetLastError();   
return false ;
} // 下传成功
return true;
}
文件能够getfile成功,但是remove时,返回值为0。