⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 connect.pas

📁 冰河反弹版之独孤夕客专版 今天我决定把这个版本的冰河反弹版程序源码公布
💻 PAS
字号:
unit Connect;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, StdCtrls, Buttons, IdStack, IdBaseComponent, IdComponent,
  IdTCPConnection, IdTCPClient, IdTCPServer;

type
  TConnectForm = class(TForm)
    lblAddress: TLabel;
    bitbtnOk: TBitBtn;
    bitbtnNo: TBitBtn;
    TCPClient: TIdTCPClient;
    edtIPAddress: TEdit;
    procedure bitbtnOkClick(Sender: TObject);
    procedure bitbtnNoClick(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  ConnectForm: TConnectForm;

implementation

{$R *.dfm}

procedure TConnectForm.bitbtnOkClick(Sender: TObject);
begin
  if edtIPAddress.Text <> '' then
  begin
    TCPClient.Host := edtIPAddress.Text;
    try
      if not TCPClient.Connected then
        TCPClient.Connect;
    except
      ShowMessage('连接错误!');
    end;
  end;
  Close;
end;

procedure TConnectForm.bitbtnNoClick(Sender: TObject);
begin
  Close;
end;

end.

⌨️ 快捷键说明

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