亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? ftptst1.cpp

?? 包含常用Internet協議TCP,UDP、HTTP、FTP、Telnet等
?? CPP
?? 第 1 頁 / 共 2 頁
字號:
/*---------------------------------------------------------------------------

Author:       Fran鏾is PIETTE
Creation:     Aug 1997 (Delphi program)
Version:      2.23
Object:       Demo for TFtpClient object (RFC 959 implementation)
              It is a graphical FTP client program
              Compatible with Delphi 1, 2 and 3
Email:        francois.piette@swing.be
              francois.piette@pophost.eunet.be francois.piette@rtfm.be
WebSite       http://www.rtfm.be/fpiette
Support:      Use the mailing list twsocket@rtfm.be See website for details.
Legal issues: Copyright (C) 1997, 1998, 1999 by Fran鏾is PIETTE
              <francois.piette@pophost.eunet.be>

              This software is provided 'as-is', without any express or
  	          implied warranty.  In no event will the author be held liable
              for any  damages arising from the use of this software.

              Permission is granted to anyone to use this software for any
              purpose, including commercial applications, and to alter it
              and redistribute it freely, subject to the following
              restrictions:

              1. The origin of this software must not be misrepresented,
                 you must not claim that you wrote the original software.
                 If you use this software in a product, an acknowledgment
                 in the product documentation would be appreciated but is
                 not required.

              2. Altered source versions must be plainly marked as such, and
                 must not be misrepresented as being the original software.

              3. This notice may not be removed or altered from any source
                 distribution.

Updates:
Sep 13, 97    Added directory functions. Added button to show how to makes
              several transferts in one session
Sep 27, 97    Change identifiers names to be more standard with other sources
Jan 10, 98    Saved edit boxes content to an IniFile, added FileSize, Quote
              and RestartGet commands
Jan 25, 1998  Completely rewritten for new component version (Asynchronous)
Feb 02, 1998  V2.17 Added a checkbox to run the synchronous or asynchronous
              version of the component methods.
Feb 15, 1998  V2.18 Removed useless wait unit from the use clause.
              Added display of winsock information at startup.
Feb 21, 1998  V2.18 ported from Delphi to C++Builder
Feb 22, 1998  V2.19 Added Append and AppendFile commands
Mar 27, 1998  V2.20 Adapted for BCB version 3.0
              See the comments for FtpClient1Progress().
Mar 06, 1999  V2.21 Minor changes
Aug 15, 1999  V2.22 Adapted for BCB4 (Moved FIniFileName initialization from
              FormCreate to form constructor).
Apr 02, 2000  V2.23 Removed "#define _WINSPOOL_" (SetPortA syndrome)
              Adapted for BCB5.

 ---------------------------------------------------------------------------*/
#if __BORLANDC__ == 0x520     // BCB1 is BC5.20   BCB3 is BC5.30
    #define _WINSOCKAPI_      // Prevent winsock.h from being included
#endif
#include <vcl\vcl.h>
#include <vcl\inifiles.hpp>
#pragma hdrstop
#include "FtpTst1.h"
#include "FtpTst2.h"

#define FTPTstVersion 223
#define SectionData    "Data"
#define KeyHostName    "HostName"
#define KeyUserName    "UserName"
#define KeyPassWord    "PassWord"
#define KeyHostDir     "HostDir"
#define KeyPort        "Port"
#define KeyHostFile    "HostFile"
#define KeyLocalFile   "LocalFile"
#define SectionWindow  "Window"
#define KeyTop         "Top"
#define KeyLeft        "Left"
#define KeyWidth       "Width"
#define KeyHeight      "Height"
#define TEMP_FILE_NAME "FTPDIR.TXT"

//---------------------------------------------------------------------------
#pragma link "Ftpcli"
#pragma resource "*.dfm"
TFtpReceiveForm *FtpReceiveForm;
//---------------------------------------------------------------------------
__fastcall TFtpReceiveForm::TFtpReceiveForm(TComponent* Owner)
	: TForm(Owner)  
{
    FIniFileName = LowerCase(ExtractFileName(Application->ExeName));
    FIniFileName = FIniFileName.SubString(1, FIniFileName.Length() - 3) + "ini";
}
//---------------------------------------------------------------------------
void __fastcall TFtpReceiveForm::FormCreate(TObject *Sender)
{
    DisplayMemo->Clear();
    InfoLabel->Caption  = "";
    StateLabel->Caption = "";
}
//---------------------------------------------------------------------------
void __fastcall TFtpReceiveForm::FormShow(TObject *Sender)
{
    TIniFile *IniFile;
    TWSAData Data;

    if (!FInitialized) {
        FInitialized = TRUE;
        IniFile =  new TIniFile(FIniFileName);
        HostNameEdit->Text  = IniFile->ReadString(SectionData, KeyHostName,
                                                  "ftp->simtel->net");
        PortEdit->Text      = IniFile->ReadString(SectionData, KeyPort,
                                                  "ftp");
        UserNameEdit->Text  = IniFile->ReadString(SectionData, KeyUserName,
                                                  "anonymous");
        PassWordEdit->Text  = IniFile->ReadString(SectionData, KeyPassWord,
                                                  "your->name@your->company->com");
        HostDirEdit->Text   = IniFile->ReadString(SectionData, KeyHostDir,
                                                  "/pub/simtelnet");
        HostFileEdit->Text  = IniFile->ReadString(SectionData, KeyHostFile,
                                                  "index->html");
        LocalFileEdit->Text = IniFile->ReadString(SectionData, KeyLocalFile,
                                                  "c:\temp\index->htm");

        Top    = IniFile->ReadInteger(SectionWindow, KeyTop,    Top);
        Left   = IniFile->ReadInteger(SectionWindow, KeyLeft,   Left);
        Width  = IniFile->ReadInteger(SectionWindow, KeyWidth,  Width);
        Height = IniFile->ReadInteger(SectionWindow, KeyHeight, Height);

        delete IniFile;

        // Display winsock info
        Data = WinsockInfo();
        DisplayMemo->Lines->Add("Winsock verion " +
                                IntToStr(LOBYTE(Data.wVersion)) + "." +
                                IntToStr(HIBYTE(Data.wVersion)));
        DisplayMemo->Lines->Add(Data.szDescription);
        DisplayMemo->Lines->Add(Data.szSystemStatus);
    }
}
//---------------------------------------------------------------------------
void __fastcall TFtpReceiveForm::FormClose(TObject *Sender,
	TCloseAction &Action)
{
    TIniFile *IniFile;

    IniFile = new TIniFile(FIniFileName);
    IniFile->WriteString(SectionData, KeyHostName,  HostNameEdit->Text);
    IniFile->WriteString(SectionData, KeyPort,      PortEdit->Text);
    IniFile->WriteString(SectionData, KeyUserName,  UserNameEdit->Text);
    IniFile->WriteString(SectionData, KeyPassWord,  PassWordEdit->Text);
    IniFile->WriteString(SectionData, KeyHostDir,   HostDirEdit->Text);
    IniFile->WriteString(SectionData, KeyHostFile,  HostFileEdit->Text);
    IniFile->WriteString(SectionData, KeyLocalFile, LocalFileEdit->Text);
    IniFile->WriteInteger(SectionWindow, KeyTop,    Top);
    IniFile->WriteInteger(SectionWindow, KeyLeft,   Left);
    IniFile->WriteInteger(SectionWindow, KeyWidth,  Width);
    IniFile->WriteInteger(SectionWindow, KeyHeight, Height);
    delete IniFile;
}
//---------------------------------------------------------------------------
void __fastcall TFtpReceiveForm::Display(
    TObject *Sender,
    AnsiString &Msg)
{
    DisplayMemo->Lines->Add(Msg);
}
//---------------------------------------------------------------------------
void __fastcall TFtpReceiveForm::ExitButtonClick(TObject *Sender)
{
    Close();    
}
//---------------------------------------------------------------------------
// BCB V1 and 3 do not agreed upon the Count argument type.
// V1 would like to have long and bcb3 would like to have int !
// In both case it is a 32 bit integer. You can safely ignore this error
// but do *NOT* remove the reference when the IDE ask for it !
// You can of course change to code to macth your BCB version !
void __fastcall TFtpReceiveForm::FtpClient1Progress(TObject *Sender, int Count,
    bool &Abort)
{
    InfoLabel->Caption = IntToStr(Count);
    InfoLabel->Repaint();
}
//---------------------------------------------------------------------------
void __fastcall TFtpReceiveForm::DisplayFile(const System::AnsiString FileName)
{
    try {
        DirectoryForm->DirListBox->Items->LoadFromFile(FileName);
    } __except (TRUE) {
        DirectoryForm->DirListBox->Clear();
    }
    DirectoryForm->ShowModal();
}
//---------------------------------------------------------------------------
void __fastcall TFtpReceiveForm::FtpClient1RequestDone(TObject *Sender,
    TFtpRequest RqType, WORD Error)
{
    DisplayMemo->Lines->Add("Request " + IntToStr(RqType) + " Done.");
    DisplayMemo->Lines->Add("StatusCode = " + IntToStr(FtpClient1->StatusCode));
    DisplayMemo->Lines->Add("LastResponse was : \"" +
                            FtpClient1->LastResponse + "\"");
    if (Error == 0)
        DisplayMemo->Lines->Add("No error");
    else
        DisplayMemo->Lines->Add("Error = " + IntToStr(Error) +
                                " (" + FtpClient1->ErrorMessage + ")");

    if (Error == 0) {
        switch (RqType) {
        case ftpDirAsync:
        case ftpDirectoryAsync:
        case ftpLsAsync:
        case ftpListAsync:
            DisplayFile(TEMP_FILE_NAME);
            break;
        case ftpSizeAsync:
            DisplayMemo->Lines->Add("File size is " +
                                    IntToStr(FtpClient1->SizeResult) +
                                    " bytes" );
            break;
        case ftpPwdAsync:
        case ftpMkdAsync:
        case ftpCDupAsync:
        case ftpCwdAsync:
            DisplayMemo->Lines->Add("Directory is \"" +
                                    FtpClient1->DirResult + "\"");
            break;
        }
    }
}
//---------------------------------------------------------------------------
void __fastcall TFtpReceiveForm::FtpClient1SessionConnected(TObject *Sender,
    WORD Error)
{
    DisplayMemo->Lines->Add("Session Connected, error = " + IntToStr(Error));
}
//---------------------------------------------------------------------------
void __fastcall TFtpReceiveForm::FtpClient1SessionClosed(TObject *Sender,
    WORD Error)
{
    DisplayMemo->Lines->Add("Session Closed, error = " + IntToStr(Error));
}
//---------------------------------------------------------------------------
void __fastcall TFtpReceiveForm::FtpClient1StateChange(TObject *Sender)
{
    StateLabel->Caption = IntToStr(FtpClient1->State);
}
//---------------------------------------------------------------------------
void __fastcall TFtpReceiveForm::ExecuteCmd(
    TSyncCmd SyncCmd,
    TASyncCmd ASyncCmd)
{
    if (SyncCheckBox->Checked) {
        if (SyncCmd())
            DisplayMemo->Lines->Add("Command Success");
        else
            DisplayMemo->Lines->Add("Command Failure");
    }
    else
        ASyncCmd();
}
//---------------------------------------------------------------------------
void __fastcall TFtpReceiveForm::OpenAsyncButtonClick(TObject *Sender)
{
    DisplayMemo->Clear();
    DisplayMemo->Lines->Add("Connect Async");
    FtpClient1->HostName        = HostNameEdit->Text;
    FtpClient1->Port            = PortEdit->Text;
    FtpClient1->DisplayFileFlag = cbDisplay->Checked;
    FtpClient1->OnDisplay       = Display;
    ExecuteCmd(FtpClient1->Open, FtpClient1->OpenAsync);
}
//---------------------------------------------------------------------------
void __fastcall TFtpReceiveForm::QuitAsyncButtonClick(TObject *Sender)
{
    FtpClient1->DisplayFileFlag = cbDisplay->Checked;
    FtpClient1->OnDisplay       = Display;
    ExecuteCmd(FtpClient1->Quit, FtpClient1->QuitAsync);
}
//---------------------------------------------------------------------------
void __fastcall TFtpReceiveForm::CwdAsyncButtonClick(TObject *Sender)
{
    FtpClient1->HostDirName     = HostDirEdit->Text;
    FtpClient1->DisplayFileFlag = cbDisplay->Checked;
    FtpClient1->OnDisplay       = Display;
    ExecuteCmd(FtpClient1->Cwd, FtpClient1->CwdAsync);
}
//---------------------------------------------------------------------------
void __fastcall TFtpReceiveForm::UserAsyncButtonClick(TObject *Sender)
{
    FtpClient1->UserName        = UserNameEdit->Text;
    FtpClient1->DisplayFileFlag = cbDisplay->Checked;
    FtpClient1->OnDisplay       = Display;
    ExecuteCmd(FtpClient1->User, FtpClient1->UserAsync);
}
//---------------------------------------------------------------------------
void __fastcall TFtpReceiveForm::PassAsyncButtonClick(TObject *Sender)
{
    FtpClient1->PassWord        = PassWordEdit->Text;
    FtpClient1->DisplayFileFlag = cbDisplay->Checked;
    FtpClient1->OnDisplay       = Display;
    ExecuteCmd(FtpClient1->Pass, FtpClient1->PassAsync);
}
//---------------------------------------------------------------------------
void __fastcall TFtpReceiveForm::ConnectAsyncButtonClick(TObject *Sender)
{
    FtpClient1->HostName        = HostNameEdit->Text;
    FtpClient1->Port            = PortEdit->Text;
    FtpClient1->UserName        = UserNameEdit->Text;
    FtpClient1->PassWord        = PassWordEdit->Text;
    FtpClient1->DisplayFileFlag = cbDisplay->Checked;
    FtpClient1->OnDisplay       = Display;
    ExecuteCmd(FtpClient1->Connect, FtpClient1->ConnectAsync);
}
//---------------------------------------------------------------------------
void __fastcall TFtpReceiveForm::GetAsyncButtonClick(TObject *Sender)
{
    FtpClient1->HostDirName     = HostDirEdit->Text;

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
日本成人在线视频网站| 欧美乱熟臀69xxxxxx| 欧美优质美女网站| 亚洲精品一区二区三区精华液| 亚洲少妇屁股交4| 国产精品一区二区无线| 91成人国产精品| 国产精品美女久久久久av爽李琼| 视频一区欧美日韩| 色综合久久久久综合| 久久九九影视网| 麻豆精品国产传媒mv男同| 欧美丝袜丝nylons| 亚洲欧美日韩在线| av亚洲精华国产精华| 国产午夜精品久久久久久免费视| 蜜臀va亚洲va欧美va天堂| 欧美视频一区二区三区在线观看 | 亚洲精品高清在线| 成人精品gif动图一区| 久久美女艺术照精彩视频福利播放| 午夜激情久久久| 欧美性色黄大片| 亚洲综合色成人| 在线观看视频欧美| 亚洲男女毛片无遮挡| 99国产精品久久久| 国产精品国产三级国产普通话99 | 国产精品网站导航| 国产另类ts人妖一区二区| 日韩亚洲国产中文字幕欧美| 天堂影院一区二区| 欧美一区二视频| 久久狠狠亚洲综合| 日韩丝袜情趣美女图片| 蜜臀久久久久久久| 日韩三级高清在线| 国模一区二区三区白浆| 精品国产污网站| 国产精品中文字幕一区二区三区| 久久美女艺术照精彩视频福利播放| 国产一区二区免费视频| xfplay精品久久| 成人三级伦理片| 亚洲三级电影全部在线观看高清| 91免费观看在线| 天天综合网天天综合色| 日韩视频免费观看高清在线视频| 另类小说欧美激情| 久久精品一区二区三区不卡| 成人综合激情网| 亚洲美女在线国产| 欧美精品久久天天躁| 九一九一国产精品| ㊣最新国产の精品bt伙计久久| 日本电影欧美片| 青青国产91久久久久久| 久久久蜜桃精品| 在线视频一区二区免费| 开心九九激情九九欧美日韩精美视频电影 | 国产伦精品一区二区三区在线观看| 国产女人aaa级久久久级| 色综合视频在线观看| 日日摸夜夜添夜夜添国产精品| 2023国产精品自拍| 欧美性受极品xxxx喷水| 激情综合五月天| 亚洲制服丝袜av| 2023国产精品自拍| 欧美吻胸吃奶大尺度电影| 国产美女视频91| 亚洲自拍偷拍网站| 国产亚洲欧洲997久久综合 | 成人听书哪个软件好| 亚洲一区二区三区激情| 久久久精品国产免大香伊| 在线观看日韩毛片| 国产成人综合亚洲91猫咪| 性做久久久久久免费观看欧美| 国产亚洲1区2区3区| 欧美日韩一区国产| av午夜精品一区二区三区| 麻豆视频观看网址久久| 一区二区三区欧美视频| 久久久久亚洲综合| 欧美日韩mp4| 日本道免费精品一区二区三区| 国产综合色精品一区二区三区| 亚洲国产精品一区二区www在线| 中文字幕免费不卡| 久久综合久久综合亚洲| 欧美男人的天堂一二区| 97se亚洲国产综合自在线观| 精品在线观看视频| 人人精品人人爱| 亚洲国产综合91精品麻豆| 亚洲日本在线观看| 国产女人aaa级久久久级| 精品人伦一区二区色婷婷| 欧美午夜精品久久久久久孕妇| 成人一区二区三区视频在线观看| 美女国产一区二区三区| 天堂久久一区二区三区| 天天影视涩香欲综合网| 一区二区三区日韩精品| 亚洲品质自拍视频网站| 一区在线播放视频| 亚洲欧洲日韩女同| 中文字幕亚洲一区二区av在线 | 日韩欧美亚洲另类制服综合在线| 欧美色图免费看| 欧美综合天天夜夜久久| 欧美在线视频你懂得| 色哟哟亚洲精品| 欧美午夜片在线看| 欧美精品成人一区二区三区四区| 91福利视频在线| 欧美日韩国产美女| 3751色影院一区二区三区| 51久久夜色精品国产麻豆| 日韩一区二区三区精品视频| 日韩欧美一区中文| 久久青草欧美一区二区三区| 欧美国产日产图区| 亚洲图片激情小说| 亚洲国产美女搞黄色| 日本不卡一区二区三区高清视频| 久久99精品久久久| 国产成人鲁色资源国产91色综| www.成人在线| 欧美色综合天天久久综合精品| 在线电影一区二区三区| 日韩女优毛片在线| 欧美国产激情一区二区三区蜜月| 日韩毛片精品高清免费| 亚洲成年人影院| 精品在线一区二区三区| 不卡的电视剧免费网站有什么| 色播五月激情综合网| 欧美一区二区精品久久911| 久久综合视频网| 一区二区三区美女| 久久99久久99精品免视看婷婷| 成人午夜看片网址| 欧美亚洲综合久久| 久久久综合激的五月天| 一区二区三区精品视频| 美女视频黄 久久| 91影院在线观看| 91精品国产色综合久久不卡电影| 欧美国产禁国产网站cc| 天天综合天天综合色| 国产99久久久久| 欧美高清视频不卡网| 亚洲国产成人自拍| 天使萌一区二区三区免费观看| 高清成人免费视频| 7777精品伊人久久久大香线蕉的 | 26uuu精品一区二区三区四区在线| 国产精品青草综合久久久久99| 天天色 色综合| 成人国产精品免费| 日韩精品一区二区三区视频| 亚洲欧美日韩国产成人精品影院 | 日日夜夜精品视频天天综合网| 国产·精品毛片| 日韩欧美一级在线播放| 亚洲理论在线观看| 国产精品一品视频| 欧美一区二区成人6969| 亚洲色图视频网| 国产精品系列在线观看| 日韩亚洲国产中文字幕欧美| 樱花草国产18久久久久| 国产精品一区二区在线观看不卡 | 免费xxxx性欧美18vr| 91成人免费在线| 亚洲国产精品t66y| 韩国v欧美v亚洲v日本v| 91精品国产福利| 亚洲成人先锋电影| 91豆麻精品91久久久久久| 国产精品麻豆久久久| 国产一区视频导航| 26uuu另类欧美| 精品在线你懂的| 精品久久久久久久一区二区蜜臀| 日韩不卡免费视频| 欧美高清视频不卡网| 香蕉成人伊视频在线观看| 欧美三级三级三级| 亚洲成人7777| 欧美肥妇bbw| 日本欧美一区二区在线观看| 欧美色国产精品| 午夜亚洲国产au精品一区二区| 欧美亚洲国产一区二区三区va| 一区二区三区欧美亚洲| 91极品视觉盛宴| 亚洲不卡在线观看|