home *** CD-ROM | disk | FTP | other *** search
/ PC Pro 1999 February / DPPCPRO0299.ISO / February / Delphi / Install / DATA.Z / ISP.PAS < prev    next >
Encoding:
Pascal/Delphi Source File  |  1996-05-30  |  60.6 KB  |  1,702 lines

  1. unit ISP;
  2.  
  3. interface
  4.  
  5. uses Ole2, OleCtl, Classes, Graphics, OleCtrls;
  6.  
  7. const
  8.  
  9. { NotificationModeConstants }
  10.  
  11.   icCompleteMode = 0;
  12.   icContinousMode = 1;
  13.  
  14. { StateConstants }
  15.  
  16.   prcConnecting = 1;
  17.   prcResolvingHost = 2;
  18.   prcHostResolved = 3;
  19.   prcConnected = 4;
  20.   prcDisconnecting = 5;
  21.   prcDisconnected = 6;
  22.  
  23. { TimeoutConstants }
  24.  
  25.   prcConnectTimeout = 1;
  26.   prcReceiveTimeout = 2;
  27.   prcUserTimeout = 65;
  28.  
  29. { MethodConstants }
  30.  
  31.   prcGet = 1;
  32.   prcHead = 2;
  33.   prcPost = 3;
  34.   prcPut = 4;
  35.  
  36. { FTPTypeConstants }
  37.  
  38.   ftpAscii = 0;
  39.   ftpEBCDIC = 1;
  40.   ftpImage = 2;
  41.   ftpBinary = 3;
  42.  
  43. { FTPModeConstants }
  44.  
  45.   ftpStream = 0;
  46.   ftpBlock = 1;
  47.   ftpCompressed = 2;
  48.  
  49. { FTPOperationConstants }
  50.  
  51.   ftpFile = 0;
  52.   ftpList = 1;
  53.   ftpNameList = 2;
  54.  
  55. { FTPProtocolStateConstants }
  56.  
  57.   ftpBase = 0;
  58.   ftpAuthentication = 1;
  59.   ftpTransaction = 2;
  60.  
  61. { HTTPProtocolStateConstants }
  62.  
  63.   httpBase = 0;
  64.   httpTransferring = 1;
  65.  
  66. { NNTPProtocolStateConstants }
  67.  
  68.   nntpBase = 0;
  69.   nntpTransaction = 1;
  70.   
  71. { PopProtocolStateConstants }
  72.  
  73.   popBase = 0;
  74.   popAuthorization = 1;
  75.   popTransaction = 2;
  76.   popUpdate = 3;
  77.  
  78. { SMTPProtocolStateConstants }
  79.  
  80.   smtpBase = 0;
  81.   smtpTransaction = 1;
  82.  
  83. { SCKSTATEConstants }
  84.  
  85.   sckClosed = 0;
  86.   sckOpen = 1;
  87.   sckListening = 2;
  88.   sckConnectionPending = 3;
  89.   sckResolvingHost = 4;
  90.   sckHostResolved = 5;
  91.   sckConnecting = 6;
  92.   sckConnected = 7;
  93.   sckClosing = 8;
  94.   sckError = 9;
  95.  
  96. { DocInput/Output Constants } 
  97.  
  98.   icDocNone = 0;
  99.   icDocBegin = 1;
  100.   icDocHeaders = 2;
  101.   icDocData = 3;
  102.   icDocError = 4;
  103.   icDocEnd = 5;
  104.   
  105. type
  106.  
  107. { TFTP }
  108.  
  109.   TFTPError = procedure(Sender: TObject; Number: Smallint; var Description: string; Scode: Integer; const Source, HelpFile: string; HelpContext: Integer; var CancelDisplay: TOleBool) of object;
  110.   TFTPTimeout = procedure(Sender: TObject; event: Smallint; var Continue: TOleBool) of object;
  111.   TFTPStateChanged = procedure(Sender: TObject; State: Smallint) of object;
  112.   TFTPProtocolStateChanged = procedure(Sender: TObject; ProtocolState: Smallint) of object;
  113.   TFTPBusy = procedure(Sender: TObject; isBusy: TOleBool) of object;
  114.   TFTPDocInput = procedure(Sender: TObject; const DocInput: Variant) of object;
  115.   TFTPDocOutput = procedure(Sender: TObject; const DocOutput: Variant) of object;
  116.   TFTPListItem = procedure(Sender: TObject; const Item: Variant) of object;
  117.  
  118.   TFTP = class(TOleControl)
  119.   private
  120.     FOnError: TFTPError;
  121.     FOnTimeout: TFTPTimeout;
  122.     FOnCancel: TNotifyEvent;
  123.     FOnStateChanged: TFTPStateChanged;
  124.     FOnProtocolStateChanged: TFTPProtocolStateChanged;
  125.     FOnBusy: TFTPBusy;
  126.     FOnLog: TNotifyEvent;
  127.     FOnDocInput: TFTPDocInput;
  128.     FOnDocOutput: TFTPDocOutput;
  129.     FOnAbort: TNotifyEvent;
  130.     FOnAccount: TNotifyEvent;
  131.     FOnChangeDir: TNotifyEvent;
  132.     FOnCreateDir: TNotifyEvent;
  133.     FOnDeleteDir: TNotifyEvent;
  134.     FOnDelFile: TNotifyEvent;
  135.     FOnHelp: TNotifyEvent;
  136.     FOnmode: TNotifyEvent;
  137.     FOnNoop: TNotifyEvent;
  138.     FOnParentDir: TNotifyEvent;
  139.     FOnPrintDir: TNotifyEvent;
  140.     FOnExecute: TNotifyEvent;
  141.     FOnStatus: TNotifyEvent;
  142.     FOnReinitialize: TNotifyEvent;
  143.     FOnSystem: TNotifyEvent;
  144.     FOnSite: TNotifyEvent;
  145.     FOnType: TNotifyEvent;
  146.     FOnListItem: TFTPListItem;
  147.     function Get_Timeout(event: Smallint): Integer; stdcall;
  148.     procedure Set_Timeout(event: Smallint; Value: Integer); stdcall;
  149.     procedure Set_EnableTimer(event: Smallint; Value: TOleBool); stdcall;
  150.   protected
  151.     procedure InitControlData; override;
  152.   public
  153.     procedure AboutBox; stdcall;
  154.     procedure Cancel; stdcall;
  155.     procedure Connect(const RemoteHost, RemotePort: Variant); stdcall;
  156.     procedure Authenticate(const UserId, Password: Variant); stdcall;
  157.     procedure SendDoc(const URL, Headers, InputData, InputFile, OutputFile: Variant); stdcall;
  158.     procedure GetDoc(const URL, Headers, OutputFile: Variant); stdcall;
  159.     procedure Abort; stdcall;
  160.     procedure Account(const Account: string); stdcall;
  161.     procedure ChangeDir(const directory: string); stdcall;
  162.     procedure CreateDir(const directory: string); stdcall;
  163.     procedure DeleteDir(const directory: string); stdcall;
  164.     procedure DeleteFile(const FileName: string); stdcall;
  165.     procedure Quit; stdcall;
  166.     procedure Help(const Help: string); stdcall;
  167.     procedure Noop; stdcall;
  168.     procedure mode(ftpMode: TOleEnum); stdcall;
  169.     procedure Type_(ftpType: TOleEnum); stdcall;
  170.     procedure List(const List: string); stdcall;
  171.     procedure NameList(const NameList: string); stdcall;
  172.     procedure ParentDir; stdcall;
  173.     procedure PrintDir; stdcall;
  174.     procedure Execute(const Execute: string); stdcall;
  175.     procedure Status(const Status: string); stdcall;
  176.     procedure PutFile(const srcFileName, destFileName: string); stdcall;
  177.     procedure Reinitialize; stdcall;
  178.     procedure System; stdcall;
  179.     procedure GetFile(const srcFileName, destFileName: string); stdcall;
  180.     procedure PutFileUnique(const FileName: string); stdcall;
  181.     procedure Site(const Site: string); stdcall;
  182.     property State: Smallint index 503 read GetSmallintProp;
  183.     property ProtocolState: Smallint index 504 read GetSmallintProp;
  184.     property ReplyString: string index 505 read GetStringProp;
  185.     property ReplyCode: Integer index 506 read GetIntegerProp;
  186.     property Errors: Variant index 508 read GetVariantProp;
  187.     property Busy: TOleBool index 509 read GetOleBoolProp;
  188.     property StateString: string index 511 read GetStringProp;
  189.     property ProtocolStateString: string index 512 read GetStringProp;
  190.     property DocInput: Variant index 1002 read GetVariantProp;
  191.     property DocOutput: Variant index 1003 read GetVariantProp;
  192.     property Operation: TOleEnum index 5 read GetOleEnumProp;
  193.     property Timeout[event: Smallint]: Integer read Get_Timeout write Set_Timeout;
  194.     property EnableTimer[event: Smallint]: TOleBool write Set_EnableTimer;
  195.   published
  196.     property RemoteHost: string index 0 read GetStringProp write SetStringProp stored False;
  197.     property RemotePort: Integer index 502 read GetIntegerProp write SetIntegerProp stored False;
  198.     property NotificationMode: Smallint index 510 read GetSmallintProp write SetSmallintProp stored False;
  199.     property Logging: TOleBool index 514 read GetOleBoolProp write SetOleBoolProp stored False;
  200.     property UserId: string index 601 read GetStringProp write SetStringProp stored False;
  201.     property Password: string index 602 read GetStringProp write SetStringProp stored False;
  202.     property URL: string index 1001 read GetStringProp write SetStringProp stored False;
  203.     property AppendToFile: TOleBool index 1 read GetOleBoolProp write SetOleBoolProp stored False;
  204.     property ListItemNotify: TOleBool index 2 read GetOleBoolProp write SetOleBoolProp stored False;
  205.     property RemoteFile: string index 3 read GetStringProp write SetStringProp stored False;
  206.     property OnError: TFTPError read FOnError write FOnError;
  207.     property OnTimeout: TFTPTimeout read FOnTimeout write FOnTimeout;
  208.     property OnCancel: TNotifyEvent read FOnCancel write FOnCancel;
  209.     property OnStateChanged: TFTPStateChanged read FOnStateChanged write FOnStateChanged;
  210.     property OnProtocolStateChanged: TFTPProtocolStateChanged read FOnProtocolStateChanged write FOnProtocolStateChanged;
  211.     property OnBusy: TFTPBusy read FOnBusy write FOnBusy;
  212.     property OnLog: TNotifyEvent read FOnLog write FOnLog;
  213.     property OnDocInput: TFTPDocInput read FOnDocInput write FOnDocInput;
  214.     property OnDocOutput: TFTPDocOutput read FOnDocOutput write FOnDocOutput;
  215.     property OnAbort: TNotifyEvent read FOnAbort write FOnAbort;
  216.     property OnAccount: TNotifyEvent read FOnAccount write FOnAccount;
  217.     property OnChangeDir: TNotifyEvent read FOnChangeDir write FOnChangeDir;
  218.     property OnCreateDir: TNotifyEvent read FOnCreateDir write FOnCreateDir;
  219.     property OnDeleteDir: TNotifyEvent read FOnDeleteDir write FOnDeleteDir;
  220.     property OnDelFile: TNotifyEvent read FOnDelFile write FOnDelFile;
  221.     property OnHelp: TNotifyEvent read FOnHelp write FOnHelp;
  222.     property Onmode: TNotifyEvent read FOnmode write FOnmode;
  223.     property OnNoop: TNotifyEvent read FOnNoop write FOnNoop;
  224.     property OnParentDir: TNotifyEvent read FOnParentDir write FOnParentDir;
  225.     property OnPrintDir: TNotifyEvent read FOnPrintDir write FOnPrintDir;
  226.     property OnExecute: TNotifyEvent read FOnExecute write FOnExecute;
  227.     property OnStatus: TNotifyEvent read FOnStatus write FOnStatus;
  228.     property OnReinitialize: TNotifyEvent read FOnReinitialize write FOnReinitialize;
  229.     property OnSystem: TNotifyEvent read FOnSystem write FOnSystem;
  230.     property OnSite: TNotifyEvent read FOnSite write FOnSite;
  231.     property OnType: TNotifyEvent read FOnType write FOnType;
  232.     property OnListItem: TFTPListItem read FOnListItem write FOnListItem;
  233.   end;
  234.  
  235. { THTML }
  236.  
  237.   THTMLError = procedure(Sender: TObject; Number: Smallint; var Description: string; Scode: Integer; const Source, HelpFile: string; HelpContext: Integer; var CancelDisplay: TOleBool) of object;
  238.   THTMLDocInput = procedure(Sender: TObject; const DocInput: Variant) of object;
  239.   THTMLDocOutput = procedure(Sender: TObject; const DocOutput: Variant) of object;
  240.   THTMLDoRequestDoc = procedure(Sender: TObject; const URL: string; const Element, DocInput: Variant; var EnableDefault: TOleBool) of object;
  241.   THTMLDoRequestEmbedded = procedure(Sender: TObject; const URL: string; const Element, DocInput: Variant; var EnableDefault: TOleBool) of object;
  242.   THTMLDoRequestSubmit = procedure(Sender: TObject; const URL: string; const Form, DocOutput: Variant; var EnableDefault: TOleBool) of object;
  243.   THTMLDoNewElement = procedure(Sender: TObject; const ElemType: string; EndTag: TOleBool; const Attrs: Variant; const Text: string; var EnableDefault: TOleBool) of object;
  244.  
  245.   THTML = class(TOleControl)
  246.   private
  247.     FOnError: THTMLError;
  248.     FOnDocInput: THTMLDocInput;
  249.     FOnDocOutput: THTMLDocOutput;
  250.     FOnParseComplete: TNotifyEvent;
  251.     FOnLayoutComplete: TNotifyEvent;
  252.     FOnTimeout: TNotifyEvent;
  253.     FOnBeginRetrieval: TNotifyEvent;
  254.     FOnUpdateRetrieval: TNotifyEvent;
  255.     FOnEndRetrieval: TNotifyEvent;
  256.     FOnDoRequestDoc: THTMLDoRequestDoc;
  257.     FOnDoRequestEmbedded: THTMLDoRequestEmbedded;
  258.     FOnDoRequestSubmit: THTMLDoRequestSubmit;
  259.     FOnDoNewElement: THTMLDoNewElement;
  260.   protected
  261.     procedure InitControlData; override;
  262.   public
  263.     procedure AboutBox; stdcall;
  264.     procedure RequestDoc(const URL: string); stdcall;
  265.     procedure RequestAllEmbedded; stdcall;
  266.     procedure Cancel(const Message: Variant); stdcall;
  267.     property DocInput: Variant index 1002 read GetVariantProp;
  268.     property DocOutput: Variant index 1003 read GetVariantProp;
  269.     property URL: string index 1001 read GetStringProp;
  270.     property RequestURL: string index 2 read GetStringProp;
  271.     property BaseURL: string index 3 read GetStringProp;
  272.     property Forms: Variant index 4 read GetVariantProp;
  273.     property TotalWidth: Integer index 5 read GetIntegerProp;
  274.     property TotalHeight: Integer index 6 read GetIntegerProp;
  275.     property RetrieveBytesTotal: Integer index 7 read GetIntegerProp;
  276.     property RetrieveBytesDone: Integer index 8 read GetIntegerProp;
  277.     property ParseDone: TOleBool index 9 read GetOleBoolProp;
  278.     property LayoutDone: TOleBool index 10 read GetOleBoolProp;
  279.     property SourceText: string index 14 read GetStringProp;
  280.     property DocBackColor: TColor index 23 read GetColorProp;
  281.     property DocForeColor: TColor index 24 read GetColorProp;
  282.     property DocLinkColor: TColor index 25 read GetColorProp;
  283.     property DocVisitedColor: TColor index 26 read GetColorProp;
  284.     property Errors: Variant index 508 read GetVariantProp;
  285.   published
  286.     property Align;
  287.     property ParentColor;
  288.     property ParentFont;
  289.     property TabStop;
  290.     property DragCursor;
  291.     property DragMode;
  292.     property ParentShowHint;
  293.     property PopupMenu;
  294.     property ShowHint;
  295.     property TabOrder;
  296.     property Visible;
  297.     property OnDragDrop;
  298.     property OnDragOver;
  299.     property OnEndDrag;
  300.     property OnEnter;
  301.     property OnExit;
  302.     property OnStartDrag;
  303.     property OnClick;
  304.     property OnDblClick;
  305.     property OnKeyDown;
  306.     property OnKeyPress;
  307.     property OnKeyUp;
  308.     property OnMouseDown;
  309.     property OnMouseMove;
  310.     property OnMouseUp;
  311.     property DeferRetrieval: TOleBool index 11 read GetOleBoolProp write SetOleBoolProp stored False;
  312.     property ViewSource: TOleBool index 12 read GetOleBoolProp write SetOleBoolProp stored False;
  313.     property RetainSource: TOleBool index 13 read GetOleBoolProp write SetOleBoolProp stored False;
  314.     property ElemNotification: TOleBool index 15 read GetOleBoolProp write SetOleBoolProp stored False;
  315.     property Timeout: Integer index 507 read GetIntegerProp write SetIntegerProp stored False;
  316.     property Redraw: TOleBool index 17 read GetOleBoolProp write SetOleBoolProp stored False;
  317.     property UnderlineLinks: TOleBool index 18 read GetOleBoolProp write SetOleBoolProp stored False;
  318.     property UseDocColors: TOleBool index 19 read GetOleBoolProp write SetOleBoolProp stored False;
  319.     property BackImage: string index 20 read GetStringProp write SetStringProp stored False;
  320.     property BackColor: TColor index -501 read GetColorProp write SetColorProp stored False;
  321.     property ForeColor: TColor index -513 read GetColorProp write SetColorProp stored False;
  322.     property LinkColor: TColor index 21 read GetColorProp write SetColorProp stored False;
  323.     property VisitedColor: TColor index 22 read GetColorProp write SetColorProp stored False;
  324.     property Font: Variant index -512 read GetVariantProp write SetVariantProp stored False;
  325.     property FixedFont: Variant index 27 read GetVariantProp write SetVariantProp stored False;
  326.     property Heading1Font: Variant index 28 read GetVariantProp write SetVariantProp stored False;
  327.     property Heading2Font: Variant index 29 read GetVariantProp write SetVariantProp stored False;
  328.     property Heading3Font: Variant index 30 read GetVariantProp write SetVariantProp stored False;
  329.     property Heading4Font: Variant index 31 read GetVariantProp write SetVariantProp stored False;
  330.     property Heading5Font: Variant index 32 read GetVariantProp write SetVariantProp stored False;
  331.     property Heading6Font: Variant index 33 read GetVariantProp write SetVariantProp stored False;
  332.     property OnError: THTMLError read FOnError write FOnError;
  333.     property OnDocInput: THTMLDocInput read FOnDocInput write FOnDocInput;
  334.     property OnDocOutput: THTMLDocOutput read FOnDocOutput write FOnDocOutput;
  335.     property OnParseComplete: TNotifyEvent read FOnParseComplete write FOnParseComplete;
  336.     property OnLayoutComplete: TNotifyEvent read FOnLayoutComplete write FOnLayoutComplete;
  337.     property OnTimeout: TNotifyEvent read FOnTimeout write FOnTimeout;
  338.     property OnBeginRetrieval: TNotifyEvent read FOnBeginRetrieval write FOnBeginRetrieval;
  339.     property OnUpdateRetrieval: TNotifyEvent read FOnUpdateRetrieval write FOnUpdateRetrieval;
  340.     property OnEndRetrieval: TNotifyEvent read FOnEndRetrieval write FOnEndRetrieval;
  341.     property OnDoRequestDoc: THTMLDoRequestDoc read FOnDoRequestDoc write FOnDoRequestDoc;
  342.     property OnDoRequestEmbedded: THTMLDoRequestEmbedded read FOnDoRequestEmbedded write FOnDoRequestEmbedded;
  343.     property OnDoRequestSubmit: THTMLDoRequestSubmit read FOnDoRequestSubmit write FOnDoRequestSubmit;
  344.     property OnDoNewElement: THTMLDoNewElement read FOnDoNewElement write FOnDoNewElement;
  345.   end; 
  346.   
  347. { THTTP }
  348.  
  349.   THTTPError = procedure(Sender: TObject; Number: Smallint; var Description: string; Scode: Integer; const Source, HelpFile: string; HelpContext: Integer; var CancelDisplay: TOleBool) of object;
  350.   THTTPTimeout = procedure(Sender: TObject; event: Smallint; var Continue: TOleBool) of object;
  351.   THTTPStateChanged = procedure(Sender: TObject; State: Smallint) of object;
  352.   THTTPProtocolStateChanged = procedure(Sender: TObject; ProtocolState: Smallint) of object;
  353.   THTTPBusy = procedure(Sender: TObject; isBusy: TOleBool) of object;
  354.   THTTPDocInput = procedure(Sender: TObject; const DocInput: Variant) of object;
  355.   THTTPDocOutput = procedure(Sender: TObject; const DocOutput: Variant) of object;
  356.  
  357.   THTTP = class(TOleControl)
  358.   private
  359.     FOnError: THTTPError;
  360.     FOnTimeout: THTTPTimeout;
  361.     FOnCancel: TNotifyEvent;
  362.     FOnStateChanged: THTTPStateChanged;
  363.     FOnProtocolStateChanged: THTTPProtocolStateChanged;
  364.     FOnBusy: THTTPBusy;
  365.     FOnLog: TNotifyEvent;
  366.     FOnDocInput: THTTPDocInput;
  367.     FOnDocOutput: THTTPDocOutput;
  368.     function Get_Timeout(event: Smallint): Integer; stdcall;
  369.     procedure Set_Timeout(event: Smallint; Value: Integer); stdcall;
  370.     procedure Set_EnableTimer(event: Smallint; Value: TOleBool); stdcall;
  371.   protected
  372.     procedure InitControlData; override;
  373.   public
  374.     procedure AboutBox; stdcall;
  375.     procedure Cancel; stdcall;
  376.     procedure SendDoc(const URL, Headers, InputData, InputFile, OutputFile: Variant); stdcall;
  377.     procedure GetDoc(const URL, Headers, OutputFile: Variant); stdcall;
  378.     property State: Smallint index 503 read GetSmallintProp;
  379.     property ProtocolState: Smallint index 504 read GetSmallintProp;
  380.     property ReplyString: string index 505 read GetStringProp;
  381.     property ReplyCode: Integer index 506 read GetIntegerProp;
  382.     property Errors: Variant index 508 read GetVariantProp;
  383.     property Busy: TOleBool index 509 read GetOleBoolProp;
  384.     property StateString: string index 511 read GetStringProp;
  385.     property ProtocolStateString: string index 512 read GetStringProp;
  386.     property DocInput: Variant index 1002 read GetVariantProp;
  387.     property DocOutput: Variant index 1003 read GetVariantProp;
  388.     property Timeout[event: Smallint]: Integer read Get_Timeout write Set_Timeout;
  389.     property EnableTimer[event: Smallint]: TOleBool write Set_EnableTimer;
  390.   published
  391.     property RemoteHost: string index 0 read GetStringProp write SetStringProp stored False;
  392.     property RemotePort: Integer index 502 read GetIntegerProp write SetIntegerProp stored False;
  393.     property NotificationMode: Smallint index 510 read GetSmallintProp write SetSmallintProp stored False;
  394.     property Logging: TOleBool index 514 read GetOleBoolProp write SetOleBoolProp stored False;
  395.     property Document: string index 10 read GetStringProp write SetStringProp stored False;
  396.     property Method: TOleEnum index 11 read GetOleEnumProp write SetOleEnumProp stored False;
  397.     property URL: string index 1001 read GetStringProp write SetStringProp stored False;
  398.     property OnError: THTTPError read FOnError write FOnError;
  399.     property OnTimeout: THTTPTimeout read FOnTimeout write FOnTimeout;
  400.     property OnCancel: TNotifyEvent read FOnCancel write FOnCancel;
  401.     property OnStateChanged: THTTPStateChanged read FOnStateChanged write FOnStateChanged;
  402.     property OnProtocolStateChanged: THTTPProtocolStateChanged read FOnProtocolStateChanged write FOnProtocolStateChanged;
  403.     property OnBusy: THTTPBusy read FOnBusy write FOnBusy;
  404.     property OnLog: TNotifyEvent read FOnLog write FOnLog;
  405.     property OnDocInput: THTTPDocInput read FOnDocInput write FOnDocInput;
  406.     property OnDocOutput: THTTPDocOutput read FOnDocOutput write FOnDocOutput;
  407.   end;
  408.  
  409. { TNNTP }
  410.   
  411.   TNNTPError = procedure(Sender: TObject; Number: Smallint; var Description: string; Scode: Integer; const Source, HelpFile: string; HelpContext: Integer; var CancelDisplay: TOleBool) of object;
  412.   TNNTPTimeout = procedure(Sender: TObject; event: Smallint; var Continue: TOleBool) of object;
  413.   TNNTPStateChanged = procedure(Sender: TObject; State: Smallint) of object;
  414.   TNNTPProtocolStateChanged = procedure(Sender: TObject; ProtocolState: Smallint) of object;
  415.   TNNTPBusy = procedure(Sender: TObject; isBusy: TOleBool) of object;
  416.   TNNTPDocInput = procedure(Sender: TObject; const DocInput: Variant) of object;
  417.   TNNTPDocOutput = procedure(Sender: TObject; const DocOutput: Variant) of object;
  418.   TNNTPAuthenticateRequest = procedure(Sender: TObject; var UserId, Password: string) of object;
  419.   TNNTPAuthenticateResponse = procedure(Sender: TObject; Authenticated: TOleBool) of object;
  420.   TNNTPBanner = procedure(Sender: TObject; const Banner: string) of object;
  421.   TNNTPSelectGroup = procedure(Sender: TObject; const groupName: string; firstMessage, lastMessage, msgCount: Integer) of object;
  422.   TNNTPNextArticle = procedure(Sender: TObject; articleNumber: Integer; const messageID: string) of object;
  423.   TNNTPlastArticle = procedure(Sender: TObject; articleNumber: Integer; const messageID: string) of object;
  424.   TNNTPArticleStatus = procedure(Sender: TObject; articleNumber: Integer; const messageID: string) of object;
  425.  
  426.   TNNTP = class(TOleControl)
  427.   private
  428.     FOnError: TNNTPError;
  429.     FOnTimeout: TNNTPTimeout;
  430.     FOnCancel: TNotifyEvent;
  431.     FOnStateChanged: TNNTPStateChanged;
  432.     FOnProtocolStateChanged: TNNTPProtocolStateChanged;
  433.     FOnBusy: TNNTPBusy;
  434.     FOnLog: TNotifyEvent;
  435.     FOnDocInput: TNNTPDocInput;
  436.     FOnDocOutput: TNNTPDocOutput;
  437.     FOnAuthenticateRequest: TNNTPAuthenticateRequest;
  438.     FOnAuthenticateResponse: TNNTPAuthenticateResponse;
  439.     FOnBanner: TNNTPBanner;
  440.     FOnSelectGroup: TNNTPSelectGroup;
  441.     FOnNextArticle: TNNTPNextArticle;
  442.     FOnlastArticle: TNNTPlastArticle;
  443.     FOnArticleStatus: TNNTPArticleStatus;
  444.     function Get_Timeout(event: Smallint): Integer; stdcall;
  445.     procedure Set_Timeout(event: Smallint; Value: Integer); stdcall;
  446.     procedure Set_EnableTimer(event: Smallint; Value: TOleBool); stdcall;
  447.   protected
  448.     procedure InitControlData; override;
  449.   public
  450.     procedure AboutBox; stdcall;
  451.     procedure Cancel; stdcall;
  452.     procedure Connect(const RemoteHost, RemotePort: Variant); stdcall;
  453.     procedure SendDoc(const URL, Headers, InputData, InputFile, OutputFile: Variant); stdcall;
  454.     procedure GetDoc(const URL, Headers, OutputFile: Variant); stdcall;
  455.     procedure GetAdministrationFile(const LastUpdate: Variant); stdcall;
  456.     procedure SelectGroup(const groupName: string); stdcall;
  457.     procedure SetNextArticle; stdcall;
  458.     procedure SetLastArticle; stdcall;
  459.     procedure GetArticleNumbers(const groupName: Variant); stdcall;
  460.     procedure GetArticleHeaders(const header: string; const firstArticle, lastArticle: Variant); stdcall;
  461.     procedure GetArticleByArticleNumber(const articleNumber: Variant); stdcall;
  462.     procedure GetArticleByMessageID(const messageID: string); stdcall;
  463.     procedure GetHeaderByArticleNumber(const articleNumber: Variant); stdcall;
  464.     procedure GetHeaderByMessageID(const messageID: string); stdcall;
  465.     procedure GetBodyByArticleNumber(const articleNumber: Variant); stdcall;
  466.     procedure GetBodyByMessageID(const messageID: string); stdcall;
  467.     procedure GetStatByArticleNumber(const articleNumber: Variant); stdcall;
  468.     procedure GetOverviewFormat; stdcall;
  469.     procedure GetOverview(const firstArticle, lastArticle: Variant); stdcall;
  470.     procedure ListGroups; stdcall;
  471.     procedure ListGroupDescriptions; stdcall;
  472.     procedure ListNewGroups(const LastUpdate: Variant); stdcall;
  473.     procedure Quit; stdcall;
  474.     property State: Smallint index 503 read GetSmallintProp;
  475.     property ProtocolState: Smallint index 504 read GetSmallintProp;
  476.     property ReplyString: string index 505 read GetStringProp;
  477.     property ReplyCode: Integer index 506 read GetIntegerProp;
  478.     property Errors: Variant index 508 read GetVariantProp;
  479.     property Busy: TOleBool index 509 read GetOleBoolProp;
  480.     property StateString: string index 511 read GetStringProp;
  481.     property ProtocolStateString: string index 512 read GetStringProp;
  482.     property DocInput: Variant index 1002 read GetVariantProp;
  483.     property DocOutput: Variant index 1003 read GetVariantProp;
  484.     property ArticleNumbersSupported: TOleBool index 1 read GetOleBoolProp;
  485.     property OverviewSupported: TOleBool index 2 read GetOleBoolProp;
  486.     property PostingAllowed: TOleBool index 3 read GetOleBoolProp;
  487.     property Timeout[event: Smallint]: Integer read Get_Timeout write Set_Timeout;
  488.     property EnableTimer[event: Smallint]: TOleBool write Set_EnableTimer;
  489.   published
  490.     property RemoteHost: string index 0 read GetStringProp write SetStringProp stored False;
  491.     property RemotePort: Integer index 502 read GetIntegerProp write SetIntegerProp stored False;
  492.     property NotificationMode: Smallint index 510 read GetSmallintProp write SetSmallintProp stored False;
  493.     property Logging: TOleBool index 514 read GetOleBoolProp write SetOleBoolProp stored False;
  494.     property URL: string index 1001 read GetStringProp write SetStringProp stored False;
  495.     property LastUpdate: TOleDate index 4 read GetOleDateProp write SetOleDateProp stored False;
  496.     property OnError: TNNTPError read FOnError write FOnError;
  497.     property OnTimeout: TNNTPTimeout read FOnTimeout write FOnTimeout;
  498.     property OnCancel: TNotifyEvent read FOnCancel write FOnCancel;
  499.     property OnStateChanged: TNNTPStateChanged read FOnStateChanged write FOnStateChanged;
  500.     property OnProtocolStateChanged: TNNTPProtocolStateChanged read FOnProtocolStateChanged write FOnProtocolStateChanged;
  501.     property OnBusy: TNNTPBusy read FOnBusy write FOnBusy;
  502.     property OnLog: TNotifyEvent read FOnLog write FOnLog;
  503.     property OnDocInput: TNNTPDocInput read FOnDocInput write FOnDocInput;
  504.     property OnDocOutput: TNNTPDocOutput read FOnDocOutput write FOnDocOutput;
  505.     property OnAuthenticateRequest: TNNTPAuthenticateRequest read FOnAuthenticateRequest write FOnAuthenticateRequest;
  506.     property OnAuthenticateResponse: TNNTPAuthenticateResponse read FOnAuthenticateResponse write FOnAuthenticateResponse;
  507.     property OnBanner: TNNTPBanner read FOnBanner write FOnBanner;
  508.     property OnSelectGroup: TNNTPSelectGroup read FOnSelectGroup write FOnSelectGroup;
  509.     property OnNextArticle: TNNTPNextArticle read FOnNextArticle write FOnNextArticle;
  510.     property OnlastArticle: TNNTPlastArticle read FOnlastArticle write FOnlastArticle;
  511.     property OnArticleStatus: TNNTPArticleStatus read FOnArticleStatus write FOnArticleStatus;
  512.   end;
  513.  
  514. { TPOP }
  515.   
  516.   TPOPError = procedure(Sender: TObject; Number: Smallint; var Description: string; Scode: Integer; const Source, HelpFile: string; HelpContext: Integer; var CancelDisplay: TOleBool) of object;
  517.   TPOPTimeout = procedure(Sender: TObject; event: Smallint; var Continue: TOleBool) of object;
  518.   TPOPStateChanged = procedure(Sender: TObject; State: Smallint) of object;
  519.   TPOPProtocolStateChanged = procedure(Sender: TObject; ProtocolState: Smallint) of object;
  520.   TPOPBusy = procedure(Sender: TObject; isBusy: TOleBool) of object;
  521.   TPOPDocOutput = procedure(Sender: TObject; const DocOutput: Variant) of object;
  522.   TPOPMessageSize = procedure(Sender: TObject; msgSize: Integer) of object;
  523.   TPOPLast = procedure(Sender: TObject; Number: Integer) of object;
  524.   TPOPRefreshMessageCount = procedure(Sender: TObject; Number: Integer) of object;
  525.  
  526.   TPOP = class(TOleControl)
  527.   private
  528.     FOnError: TPOPError;
  529.     FOnTimeout: TPOPTimeout;
  530.     FOnCancel: TNotifyEvent;
  531.     FOnStateChanged: TPOPStateChanged;
  532.     FOnProtocolStateChanged: TPOPProtocolStateChanged;
  533.     FOnBusy: TPOPBusy;
  534.     FOnLog: TNotifyEvent;
  535.     FOnDocOutput: TPOPDocOutput;
  536.     FOnMessageSize: TPOPMessageSize;
  537.     FOnDelete: TNotifyEvent;
  538.     FOnReset: TNotifyEvent;
  539.     FOnLast: TPOPLast;
  540.     FOnNoop: TNotifyEvent;
  541.     FOnRefreshMessageCount: TPOPRefreshMessageCount;
  542.     function Get_Timeout(event: Smallint): Integer; stdcall;
  543.     procedure Set_Timeout(event: Smallint; Value: Integer); stdcall;
  544.     procedure Set_EnableTimer(event: Smallint; Value: TOleBool); stdcall;
  545.   protected
  546.     procedure InitControlData; override;
  547.   public
  548.     procedure AboutBox; stdcall;
  549.     procedure Cancel; stdcall;
  550.     procedure Connect(const RemoteHost, RemotePort: Variant); stdcall;
  551.     procedure Authenticate(const UserId, Password: Variant); stdcall;
  552.     procedure GetDoc(const URL, Headers, OutputFile: Variant); stdcall;
  553.     procedure MessageSize(MessageNumber: Smallint); stdcall;
  554.     procedure RetrieveMessage(MessageNumber: Smallint); stdcall;
  555.     procedure Delete(MessageNumber: Smallint); stdcall;
  556.     procedure Reset; stdcall;
  557.     procedure Last; stdcall;
  558.     procedure Noop; stdcall;
  559.     procedure TopMessage(MessageNumber: Smallint); stdcall;
  560.     procedure Quit; stdcall;
  561.     procedure RefreshMessageCount; stdcall;
  562.     property State: Smallint index 503 read GetSmallintProp;
  563.     property ProtocolState: Smallint index 504 read GetSmallintProp;
  564.     property ReplyString: string index 505 read GetStringProp;
  565.     property ReplyCode: Integer index 506 read GetIntegerProp;
  566.     property Errors: Variant index 508 read GetVariantProp;
  567.     property Busy: TOleBool index 509 read GetOleBoolProp;
  568.     property StateString: string index 511 read GetStringProp;
  569.     property ProtocolStateString: string index 512 read GetStringProp;
  570.     property DocOutput: Variant index 1003 read GetVariantProp;
  571.     property TopSupported: TOleBool index 2452 read GetOleBoolProp;
  572.     property MessageCount: Smallint index 2454 read GetSmallintProp;
  573.     property Timeout[event: Smallint]: Integer read Get_Timeout write Set_Timeout;
  574.     property EnableTimer[event: Smallint]: TOleBool write Set_EnableTimer;
  575.   published
  576.     property RemoteHost: string index 0 read GetStringProp write SetStringProp stored False;
  577.     property RemotePort: Integer index 502 read GetIntegerProp write SetIntegerProp stored False;
  578.     property NotificationMode: Smallint index 510 read GetSmallintProp write SetSmallintProp stored False;
  579.     property Logging: TOleBool index 514 read GetOleBoolProp write SetOleBoolProp stored False;
  580.     property UserId: string index 601 read GetStringProp write SetStringProp stored False;
  581.     property Password: string index 602 read GetStringProp write SetStringProp stored False;
  582.     property URL: string index 1001 read GetStringProp write SetStringProp stored False;
  583.     property TopLines: Integer index 2453 read GetIntegerProp write SetIntegerProp stored False;
  584.     property OnError: TPOPError read FOnError write FOnError;
  585.     property OnTimeout: TPOPTimeout read FOnTimeout write FOnTimeout;
  586.     property OnCancel: TNotifyEvent read FOnCancel write FOnCancel;
  587.     property OnStateChanged: TPOPStateChanged read FOnStateChanged write FOnStateChanged;
  588.     property OnProtocolStateChanged: TPOPProtocolStateChanged read FOnProtocolStateChanged write FOnProtocolStateChanged;
  589.     property OnBusy: TPOPBusy read FOnBusy write FOnBusy;
  590.     property OnLog: TNotifyEvent read FOnLog write FOnLog;
  591.     property OnDocOutput: TPOPDocOutput read FOnDocOutput write FOnDocOutput;
  592.     property OnMessageSize: TPOPMessageSize read FOnMessageSize write FOnMessageSize;
  593.     property OnDelete: TNotifyEvent read FOnDelete write FOnDelete;
  594.     property OnReset: TNotifyEvent read FOnReset write FOnReset;
  595.     property OnLast: TPOPLast read FOnLast write FOnLast;
  596.     property OnNoop: TNotifyEvent read FOnNoop write FOnNoop;
  597.     property OnRefreshMessageCount: TPOPRefreshMessageCount read FOnRefreshMessageCount write FOnRefreshMessageCount;
  598.   end;
  599.  
  600. { TSMTP }
  601.  
  602.   TSMTPError = procedure(Sender: TObject; Number: Smallint; var Description: string; Scode: Integer; const Source, HelpFile: string; HelpContext: Integer; var CancelDisplay: TOleBool) of object;
  603.   TSMTPTimeout = procedure(Sender: TObject; event: Smallint; var Continue: TOleBool) of object;
  604.   TSMTPStateChanged = procedure(Sender: TObject; State: Smallint) of object;
  605.   TSMTPProtocolStateChanged = procedure(Sender: TObject; ProtocolState: Smallint) of object;
  606.   TSMTPBusy = procedure(Sender: TObject; isBusy: TOleBool) of object;
  607.   TSMTPDocInput = procedure(Sender: TObject; const DocInput: Variant) of object;
  608.  
  609.   TSMTP = class(TOleControl)
  610.   private
  611.     FOnError: TSMTPError;
  612.     FOnTimeout: TSMTPTimeout;
  613.     FOnCancel: TNotifyEvent;
  614.     FOnStateChanged: TSMTPStateChanged;
  615.     FOnProtocolStateChanged: TSMTPProtocolStateChanged;
  616.     FOnBusy: TSMTPBusy;
  617.     FOnLog: TNotifyEvent;
  618.     FOnDocInput: TSMTPDocInput;
  619.     FOnReset: TNotifyEvent;
  620.     FOnVerify: TNotifyEvent;
  621.     FOnExpand: TNotifyEvent;
  622.     FOnHelp: TNotifyEvent;
  623.     FOnNoop: TNotifyEvent;
  624.     function Get_Timeout(event: Smallint): Integer; stdcall;
  625.     procedure Set_Timeout(event: Smallint; Value: Integer); stdcall;
  626.     procedure Set_EnableTimer(event: Smallint; Value: TOleBool); stdcall;
  627.   protected
  628.     procedure InitControlData; override;
  629.   public
  630.     procedure AboutBox; stdcall;
  631.     procedure Cancel; stdcall;
  632.     procedure Connect(const RemoteHost, RemotePort: Variant); stdcall;
  633.     procedure SendDoc(const URL, Headers, InputData, InputFile, OutputFile: Variant); stdcall;
  634.     procedure Reset; stdcall;
  635.     procedure Verify(const name: string); stdcall;
  636.     procedure Expand(const name: string); stdcall;
  637.     procedure Help(const helpTopic: Variant); stdcall;
  638.     procedure Noop; stdcall;
  639.     procedure Quit; stdcall;
  640.     property State: Smallint index 503 read GetSmallintProp;
  641.     property ProtocolState: Smallint index 504 read GetSmallintProp;
  642.     property ReplyString: string index 505 read GetStringProp;
  643.     property ReplyCode: Integer index 506 read GetIntegerProp;
  644.     property Errors: Variant index 508 read GetVariantProp;
  645.     property Busy: TOleBool index 509 read GetOleBoolProp;
  646.     property StateString: string index 511 read GetStringProp;
  647.     property ProtocolStateString: string index 512 read GetStringProp;
  648.     property DocInput: Variant index 1002 read GetVariantProp;
  649.     property Timeout[event: Smallint]: Integer read Get_Timeout write Set_Timeout;
  650.     property EnableTimer[event: Smallint]: TOleBool write Set_EnableTimer;
  651.   published
  652.     property RemoteHost: string index 0 read GetStringProp write SetStringProp stored False;
  653.     property RemotePort: Integer index 502 read GetIntegerProp write SetIntegerProp stored False;
  654.     property NotificationMode: Smallint index 510 read GetSmallintProp write SetSmallintProp stored False;
  655.     property Logging: TOleBool index 514 read GetOleBoolProp write SetOleBoolProp stored False;
  656.     property URL: string index 1001 read GetStringProp write SetStringProp stored False;
  657.     property OnError: TSMTPError read FOnError write FOnError;
  658.     property OnTimeout: TSMTPTimeout read FOnTimeout write FOnTimeout;
  659.     property OnCancel: TNotifyEvent read FOnCancel write FOnCancel;
  660.     property OnStateChanged: TSMTPStateChanged read FOnStateChanged write FOnStateChanged;
  661.     property OnProtocolStateChanged: TSMTPProtocolStateChanged read FOnProtocolStateChanged write FOnProtocolStateChanged;
  662.     property OnBusy: TSMTPBusy read FOnBusy write FOnBusy;
  663.     property OnLog: TNotifyEvent read FOnLog write FOnLog;
  664.     property OnDocInput: TSMTPDocInput read FOnDocInput write FOnDocInput;
  665.     property OnReset: TNotifyEvent read FOnReset write FOnReset;
  666.     property OnVerify: TNotifyEvent read FOnVerify write FOnVerify;
  667.     property OnExpand: TNotifyEvent read FOnExpand write FOnExpand;
  668.     property OnHelp: TNotifyEvent read FOnHelp write FOnHelp;
  669.     property OnNoop: TNotifyEvent read FOnNoop write FOnNoop;
  670.   end;
  671.  
  672. { TTCP }
  673.  
  674.   TTCPError = procedure(Sender: TObject; Number: Smallint; var Description: string; Scode: Integer; const Source, HelpFile: string; HelpContext: Integer; var CancelDisplay: TOleBool) of object;
  675.   TTCPDataArrival = procedure(Sender: TObject; bytesTotal: Integer) of object;
  676.   TTCPConnectionRequest = procedure(Sender: TObject; requestID: Integer) of object;
  677.   TTCPSendProgress = procedure(Sender: TObject; bytesSent, bytesRemaining: Integer) of object;
  678.  
  679.   TTCP = class(TOleControl)
  680.   private
  681.     FOnError: TTCPError;
  682.     FOnDataArrival: TTCPDataArrival;
  683.     FOnConnect: TNotifyEvent;
  684.     FOnConnectionRequest: TTCPConnectionRequest;
  685.     FOnClose: TNotifyEvent;
  686.     FOnSendProgress: TTCPSendProgress;
  687.     FOnSendComplete: TNotifyEvent;
  688.   protected
  689.     procedure InitControlData; override;
  690.   public
  691.     procedure AboutBox; stdcall;
  692.     procedure Connect(const RemoteHost, RemotePort: Variant); stdcall;
  693.     procedure Listen; stdcall;
  694.     procedure Accept(requestID: Integer); stdcall;
  695.     procedure SendData(const data: Variant); stdcall;
  696.     procedure GetData(var data: Variant; const type_, maxLen: Variant); stdcall;
  697.     procedure PeekData(var data: Variant; const type_, maxLen: Variant); stdcall;
  698.     procedure Close; stdcall;
  699.     property RemoteHostIP: string index 1001 read GetStringProp;
  700.     property LocalHostName: string index 1002 read GetStringProp;
  701.     property LocalIP: string index 1003 read GetStringProp;
  702.     property SocketHandle: Integer index 1004 read GetIntegerProp;
  703.     property State: Smallint index 503 read GetSmallintProp;
  704.     property BytesReceived: Integer index 1101 read GetIntegerProp;
  705.   published
  706.     property RemoteHost: string index 0 read GetStringProp write SetStringProp stored False;
  707.     property RemotePort: Integer index 502 read GetIntegerProp write SetIntegerProp stored False;
  708.     property LocalPort: Integer index 1010 read GetIntegerProp write SetIntegerProp stored False;
  709.     property OnError: TTCPError read FOnError write FOnError;
  710.     property OnDataArrival: TTCPDataArrival read FOnDataArrival write FOnDataArrival;
  711.     property OnConnect: TNotifyEvent read FOnConnect write FOnConnect;
  712.     property OnConnectionRequest: TTCPConnectionRequest read FOnConnectionRequest write FOnConnectionRequest;
  713.     property OnClose: TNotifyEvent read FOnClose write FOnClose;
  714.     property OnSendProgress: TTCPSendProgress read FOnSendProgress write FOnSendProgress;
  715.     property OnSendComplete: TNotifyEvent read FOnSendComplete write FOnSendComplete;
  716.   end;
  717.  
  718. { TUDP }
  719.   
  720.   TUDPError = procedure(Sender: TObject; Number: Smallint; var Description: string; Scode: Integer; const Source, HelpFile: string; HelpContext: Integer; var CancelDisplay: TOleBool) of object;
  721.   TUDPDataArrival = procedure(Sender: TObject; bytesTotal: Integer) of object;
  722.  
  723.   TUDP = class(TOleControl)
  724.   private
  725.     FOnError: TUDPError;
  726.     FOnDataArrival: TUDPDataArrival;
  727.   protected
  728.     procedure InitControlData; override;
  729.   public
  730.     procedure AboutBox; stdcall;
  731.     procedure SendData(const data: Variant); stdcall;
  732.     procedure GetData(var data: Variant; const type_: Variant); stdcall;
  733.     property RemoteHostIP: string index 1001 read GetStringProp;
  734.     property LocalHostName: string index 1002 read GetStringProp;
  735.     property LocalIP: string index 1003 read GetStringProp;
  736.     property SocketHandle: Integer index 1004 read GetIntegerProp;
  737.   published
  738.     property RemoteHost: string index 0 read GetStringProp write SetStringProp stored False;
  739.     property RemotePort: Integer index 502 read GetIntegerProp write SetIntegerProp stored False;
  740.     property LocalPort: Integer index 1010 read GetIntegerProp write SetIntegerProp stored False;
  741.     property OnError: TUDPError read FOnError write FOnError;
  742.     property OnDataArrival: TUDPDataArrival read FOnDataArrival write FOnDataArrival;
  743.   end;
  744.  
  745. procedure Register;  
  746.   
  747. implementation
  748.  
  749. {$J+}
  750.  
  751. { TFTP }
  752.  
  753. procedure TFTP.InitControlData;
  754. const
  755.   CEventDispIDs: array[0..26] of Integer = (
  756.     $FFFFFDA0, $00000227, $00000228, $00000229, $0000022A, $0000022B,
  757.     $0000022C, $000003F8, $000003F9, $0000002B, $0000002C, $0000002D,
  758.     $0000002F, $00000030, $00000031, $00000036, $00000037, $00000038,
  759.     $00000039, $0000003A, $0000003C, $0000003E, $0000003F, $00000040,
  760.     $00000042, $00000044, $00000043);
  761.   CControlData: TControlData = (
  762.     ClassID: (
  763.       D1:$B7FC354C;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  764.     EventIID: (
  765.       D1:$B7FC354B;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  766.     EventCount: 27;
  767.     EventDispIDs: @CEventDispIDs;
  768.     LicenseKey: nil;
  769.     Flags: $00000000);
  770. begin
  771.   ControlData := @CControlData;
  772. end;
  773.  
  774. procedure TFTP.AboutBox;
  775. const
  776.   DispInfo: array[0..7] of Byte = ($D8,$FD,$FF,$FF,$00,$01,$00,$00);
  777. begin
  778.   InvokeMethod(DispInfo, nil);
  779. end;
  780.  
  781. procedure TFTP.Cancel;
  782. const
  783.   DispInfo: array[0..7] of Byte = ($08,$02,$00,$00,$00,$01,$00,$00);
  784. begin
  785.   InvokeMethod(DispInfo, nil);
  786. end;
  787.  
  788. procedure TFTP.Connect;
  789. const
  790.   DispInfo: array[0..9] of Byte = ($09,$02,$00,$00,$00,$01,$02,$00,$0C,$0C);
  791. begin
  792.   InvokeMethod(DispInfo, nil);
  793. end;
  794.  
  795. procedure TFTP.Authenticate;
  796. const
  797.   DispInfo: array[0..9] of Byte = ($62,$02,$00,$00,$00,$01,$02,$00,$0C,$0C);
  798. begin
  799.   InvokeMethod(DispInfo, nil);
  800. end;
  801.  
  802. procedure TFTP.SendDoc;
  803. const
  804.   DispInfo: array[0..12] of Byte = ($ED,$03,$00,$00,$00,$01,$05,$00,$0C,$0C,$0C,$0C,$0C);
  805. begin
  806.   InvokeMethod(DispInfo, nil);
  807. end;
  808.  
  809. procedure TFTP.GetDoc;
  810. const
  811.   DispInfo: array[0..10] of Byte = ($EC,$03,$00,$00,$00,$01,$03,$00,$0C,$0C,$0C);
  812. begin
  813.   InvokeMethod(DispInfo, nil);
  814. end;
  815.  
  816. procedure TFTP.Abort;
  817. const
  818.   DispInfo: array[0..7] of Byte = ($08,$00,$00,$00,$00,$01,$00,$00);
  819. begin
  820.   InvokeMethod(DispInfo, nil);
  821. end;
  822.  
  823. procedure TFTP.Account;
  824. const
  825.   DispInfo: array[0..8] of Byte = ($09,$00,$00,$00,$00,$01,$01,$00,$08);
  826. begin
  827.   InvokeMethod(DispInfo, nil);
  828. end;
  829.  
  830. procedure TFTP.ChangeDir;
  831. const
  832.   DispInfo: array[0..8] of Byte = ($0A,$00,$00,$00,$00,$01,$01,$00,$08);
  833. begin
  834.   InvokeMethod(DispInfo, nil);
  835. end;
  836.  
  837. procedure TFTP.CreateDir;
  838. const
  839.   DispInfo: array[0..8] of Byte = ($0B,$00,$00,$00,$00,$01,$01,$00,$08);
  840. begin
  841.   InvokeMethod(DispInfo, nil);
  842. end;
  843.  
  844. procedure TFTP.DeleteDir;
  845. const
  846.   DispInfo: array[0..8] of Byte = ($0C,$00,$00,$00,$00,$01,$01,$00,$08);
  847. begin
  848.   InvokeMethod(DispInfo, nil);
  849. end;
  850.  
  851. procedure TFTP.DeleteFile;
  852. const
  853.   DispInfo: array[0..8] of Byte = ($0D,$00,$00,$00,$00,$01,$01,$00,$08);
  854. begin
  855.   InvokeMethod(DispInfo, nil);
  856. end;
  857.  
  858. procedure TFTP.Quit;
  859. const
  860.   DispInfo: array[0..7] of Byte = ($0E,$00,$00,$00,$00,$01,$00,$00);
  861. begin
  862.   InvokeMethod(DispInfo, nil);
  863. end;
  864.  
  865. procedure TFTP.Help;
  866. const
  867.   DispInfo: array[0..8] of Byte = ($10,$00,$00,$00,$00,$01,$01,$00,$08);
  868. begin
  869.   InvokeMethod(DispInfo, nil);
  870. end;
  871.  
  872. procedure TFTP.Noop;
  873. const
  874.   DispInfo: array[0..7] of Byte = ($12,$00,$00,$00,$00,$01,$00,$00);
  875. begin
  876.   InvokeMethod(DispInfo, nil);
  877. end;
  878.  
  879. procedure TFTP.mode;
  880. const
  881.   DispInfo: array[0..8] of Byte = ($13,$00,$00,$00,$00,$01,$01,$00,$02);
  882. begin
  883.   InvokeMethod(DispInfo, nil);
  884. end;
  885.  
  886. procedure TFTP.Type_;
  887. const
  888.   DispInfo: array[0..8] of Byte = ($14,$00,$00,$00,$00,$01,$01,$00,$02);
  889. begin
  890.   InvokeMethod(DispInfo, nil);
  891. end;
  892.  
  893. procedure TFTP.List;
  894. const
  895.   DispInfo: array[0..8] of Byte = ($15,$00,$00,$00,$00,$01,$01,$00,$08);
  896. begin
  897.   InvokeMethod(DispInfo, nil);
  898. end;
  899.  
  900. procedure TFTP.NameList;
  901. const
  902.   DispInfo: array[0..8] of Byte = ($16,$00,$00,$00,$00,$01,$01,$00,$08);
  903. begin
  904.   InvokeMethod(DispInfo, nil);
  905. end;
  906.  
  907. procedure TFTP.ParentDir;
  908. const
  909.   DispInfo: array[0..7] of Byte = ($17,$00,$00,$00,$00,$01,$00,$00);
  910. begin
  911.   InvokeMethod(DispInfo, nil);
  912. end;
  913.  
  914. procedure TFTP.PrintDir;
  915. const
  916.   DispInfo: array[0..7] of Byte = ($18,$00,$00,$00,$00,$01,$00,$00);
  917. begin
  918.   InvokeMethod(DispInfo, nil);
  919. end;
  920.  
  921. procedure TFTP.Execute;
  922. const
  923.   DispInfo: array[0..8] of Byte = ($19,$00,$00,$00,$00,$01,$01,$00,$08);
  924. begin
  925.   InvokeMethod(DispInfo, nil);
  926. end;
  927.  
  928. procedure TFTP.Status;
  929. const
  930.   DispInfo: array[0..8] of Byte = ($1A,$00,$00,$00,$00,$01,$01,$00,$08);
  931. begin
  932.   InvokeMethod(DispInfo, nil);
  933. end;
  934.  
  935. procedure TFTP.PutFile;
  936. const
  937.   DispInfo: array[0..9] of Byte = ($1B,$00,$00,$00,$00,$01,$02,$00,$08,$08);
  938. begin
  939.   InvokeMethod(DispInfo, nil);
  940. end;
  941.  
  942. procedure TFTP.Reinitialize;
  943. const
  944.   DispInfo: array[0..7] of Byte = ($1C,$00,$00,$00,$00,$01,$00,$00);
  945. begin
  946.   InvokeMethod(DispInfo, nil);
  947. end;
  948.  
  949. procedure TFTP.System;
  950. const
  951.   DispInfo: array[0..7] of Byte = ($1D,$00,$00,$00,$00,$01,$00,$00);
  952. begin
  953.   InvokeMethod(DispInfo, nil);
  954. end;
  955.  
  956. procedure TFTP.GetFile;
  957. const
  958.   DispInfo: array[0..9] of Byte = ($1E,$00,$00,$00,$00,$01,$02,$00,$08,$08);
  959. begin
  960.   InvokeMethod(DispInfo, nil);
  961. end;
  962.  
  963. procedure TFTP.PutFileUnique;
  964. const
  965.   DispInfo: array[0..8] of Byte = ($1F,$00,$00,$00,$00,$01,$01,$00,$08);
  966. begin
  967.   InvokeMethod(DispInfo, nil);
  968. end;
  969.  
  970. procedure TFTP.Site;
  971. const
  972.   DispInfo: array[0..8] of Byte = ($20,$00,$00,$00,$00,$01,$01,$00,$08);
  973. begin
  974.   InvokeMethod(DispInfo, nil);
  975. end;
  976.  
  977. function TFTP.Get_Timeout;
  978. const
  979.   DispInfo: array[0..8] of Byte = ($FB,$01,$00,$00,$03,$02,$01,$00,$02);
  980. begin
  981.   InvokeMethod(DispInfo, @Result);
  982. end;
  983.  
  984. procedure TFTP.Set_Timeout;
  985. const
  986.   DispInfo: array[0..9] of Byte = ($FB,$01,$00,$00,$00,$04,$02,$00,$02,$03);
  987. begin
  988.   InvokeMethod(DispInfo, nil);
  989. end;
  990.  
  991. procedure TFTP.Set_EnableTimer;
  992. const
  993.   DispInfo: array[0..9] of Byte = ($01,$02,$00,$00,$00,$04,$02,$00,$02,$0B);
  994. begin
  995.   InvokeMethod(DispInfo, nil);
  996. end;
  997.  
  998. { THTML }
  999.  
  1000. procedure THTML.InitControlData;
  1001. const
  1002.   CEventDispIDs: array[0..12] of Integer = (
  1003.     $FFFFFDA0, $000003F8, $000003F9, $00000001, $00000002, $00000227,
  1004.     $00000004, $00000005, $00000006, $00000007, $00000008, $00000009,
  1005.     $0000000A);
  1006.   CControlData: TControlData = (
  1007.     ClassID: (
  1008.       D1:$B7FC355E;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1009.     EventIID: (
  1010.       D1:$B7FC355D;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1011.     EventCount: 13;
  1012.     EventDispIDs: @CEventDispIDs;
  1013.     LicenseKey: nil;
  1014.     Flags: $00000007);
  1015. begin
  1016.   ControlData := @CControlData;
  1017. end;
  1018.  
  1019. procedure THTML.AboutBox;
  1020. const
  1021.   DispInfo: array[0..7] of Byte = ($D8,$FD,$FF,$FF,$00,$01,$00,$00);
  1022. begin
  1023.   InvokeMethod(DispInfo, nil);
  1024. end;
  1025.  
  1026. procedure THTML.RequestDoc;
  1027. const
  1028.   DispInfo: array[0..8] of Byte = ($22,$00,$00,$00,$00,$01,$01,$00,$08);
  1029. begin
  1030.   InvokeMethod(DispInfo, nil);
  1031. end;
  1032.  
  1033. procedure THTML.RequestAllEmbedded;
  1034. const
  1035.   DispInfo: array[0..7] of Byte = ($23,$00,$00,$00,$00,$01,$00,$00);
  1036. begin
  1037.   InvokeMethod(DispInfo, nil);
  1038. end;
  1039.  
  1040. procedure THTML.Cancel;
  1041. const
  1042.   DispInfo: array[0..8] of Byte = ($08,$02,$00,$00,$00,$01,$01,$00,$0C);
  1043. begin
  1044.   InvokeMethod(DispInfo, nil);
  1045. end;
  1046.  
  1047. { THTTP }
  1048.  
  1049. procedure THTTP.InitControlData;
  1050. const
  1051.   CEventDispIDs: array[0..8] of Integer = (
  1052.     $FFFFFDA0, $00000227, $00000228, $00000229, $0000022A, $0000022B,
  1053.     $0000022C, $000003F8, $000003F9);
  1054.   CControlData: TControlData = (
  1055.     ClassID: (
  1056.       D1:$B7FC3563;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1057.     EventIID: (
  1058.       D1:$B7FC3562;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1059.     EventCount: 9;
  1060.     EventDispIDs: @CEventDispIDs;
  1061.     LicenseKey: nil;
  1062.     Flags: $00000000);
  1063. begin
  1064.   ControlData := @CControlData;
  1065. end;
  1066.  
  1067. procedure THTTP.AboutBox;
  1068. const
  1069.   DispInfo: array[0..7] of Byte = ($D8,$FD,$FF,$FF,$00,$01,$00,$00);
  1070. begin
  1071.   InvokeMethod(DispInfo, nil);
  1072. end;
  1073.  
  1074. procedure THTTP.Cancel;
  1075. const
  1076.   DispInfo: array[0..7] of Byte = ($08,$02,$00,$00,$00,$01,$00,$00);
  1077. begin
  1078.   InvokeMethod(DispInfo, nil);
  1079. end;
  1080.  
  1081. procedure THTTP.SendDoc;
  1082. const
  1083.   DispInfo: array[0..12] of Byte = ($ED,$03,$00,$00,$00,$01,$05,$00,$0C,$0C,$0C,$0C,$0C);
  1084. begin
  1085.   InvokeMethod(DispInfo, nil);
  1086. end;
  1087.  
  1088. procedure THTTP.GetDoc;
  1089. const
  1090.   DispInfo: array[0..10] of Byte = ($EC,$03,$00,$00,$00,$01,$03,$00,$0C,$0C,$0C);
  1091. begin
  1092.   InvokeMethod(DispInfo, nil);
  1093. end;
  1094.  
  1095. function THTTP.Get_Timeout;
  1096. const
  1097.   DispInfo: array[0..8] of Byte = ($FB,$01,$00,$00,$03,$02,$01,$00,$02);
  1098. begin
  1099.   InvokeMethod(DispInfo, @Result);
  1100. end;
  1101.  
  1102. procedure THTTP.Set_Timeout;
  1103. const
  1104.   DispInfo: array[0..9] of Byte = ($FB,$01,$00,$00,$00,$04,$02,$00,$02,$03);
  1105. begin
  1106.   InvokeMethod(DispInfo, nil);
  1107. end;
  1108.  
  1109. procedure THTTP.Set_EnableTimer;
  1110. const
  1111.   DispInfo: array[0..9] of Byte = ($01,$02,$00,$00,$00,$04,$02,$00,$02,$0B);
  1112. begin
  1113.   InvokeMethod(DispInfo, nil);
  1114. end;
  1115.  
  1116. { TNNTP }
  1117.  
  1118. procedure TNNTP.InitControlData;
  1119. const
  1120.   CEventDispIDs: array[0..15] of Integer = (
  1121.     $FFFFFDA0, $00000227, $00000228, $00000229, $0000022A, $0000022B,
  1122.     $0000022C, $000003F8, $000003F9, $00000000, $00000001, $00000002,
  1123.     $00000003, $00000004, $00000005, $00000006);
  1124.   CControlData: TControlData = (
  1125.     ClassID: (
  1126.       D1:$B7FC3568;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1127.     EventIID: (
  1128.       D1:$B7FC3567;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1129.     EventCount: 16;
  1130.     EventDispIDs: @CEventDispIDs;
  1131.     LicenseKey: nil;
  1132.     Flags: $00000000);
  1133. begin
  1134.   ControlData := @CControlData;
  1135. end;
  1136.  
  1137. procedure TNNTP.AboutBox;
  1138. const
  1139.   DispInfo: array[0..7] of Byte = ($D8,$FD,$FF,$FF,$00,$01,$00,$00);
  1140. begin
  1141.   InvokeMethod(DispInfo, nil);
  1142. end;
  1143.  
  1144. procedure TNNTP.Cancel;
  1145. const
  1146.   DispInfo: array[0..7] of Byte = ($08,$02,$00,$00,$00,$01,$00,$00);
  1147. begin
  1148.   InvokeMethod(DispInfo, nil);
  1149. end;
  1150.  
  1151. procedure TNNTP.Connect;
  1152. const
  1153.   DispInfo: array[0..9] of Byte = ($09,$02,$00,$00,$00,$01,$02,$00,$0C,$0C);
  1154. begin
  1155.   InvokeMethod(DispInfo, nil);
  1156. end;
  1157.  
  1158. procedure TNNTP.SendDoc;
  1159. const
  1160.   DispInfo: array[0..12] of Byte = ($ED,$03,$00,$00,$00,$01,$05,$00,$0C,$0C,$0C,$0C,$0C);
  1161. begin
  1162.   InvokeMethod(DispInfo, nil);
  1163. end;
  1164.  
  1165. procedure TNNTP.GetDoc;
  1166. const
  1167.   DispInfo: array[0..10] of Byte = ($EC,$03,$00,$00,$00,$01,$03,$00,$0C,$0C,$0C);
  1168. begin
  1169.   InvokeMethod(DispInfo, nil);
  1170. end;
  1171.  
  1172. procedure TNNTP.GetAdministrationFile;
  1173. const
  1174.   DispInfo: array[0..8] of Byte = ($05,$00,$00,$00,$00,$01,$01,$00,$0C);
  1175. begin
  1176.   InvokeMethod(DispInfo, nil);
  1177. end;
  1178.  
  1179. procedure TNNTP.SelectGroup;
  1180. const
  1181.   DispInfo: array[0..8] of Byte = ($06,$00,$00,$00,$00,$01,$01,$00,$08);
  1182. begin
  1183.   InvokeMethod(DispInfo, nil);
  1184. end;
  1185.  
  1186. procedure TNNTP.SetNextArticle;
  1187. const
  1188.   DispInfo: array[0..7] of Byte = ($07,$00,$00,$00,$00,$01,$00,$00);
  1189. begin
  1190.   InvokeMethod(DispInfo, nil);
  1191. end;
  1192.  
  1193. procedure TNNTP.SetLastArticle;
  1194. const
  1195.   DispInfo: array[0..7] of Byte = ($08,$00,$00,$00,$00,$01,$00,$00);
  1196. begin
  1197.   InvokeMethod(DispInfo, nil);
  1198. end;
  1199.  
  1200. procedure TNNTP.GetArticleNumbers;
  1201. const
  1202.   DispInfo: array[0..8] of Byte = ($09,$00,$00,$00,$00,$01,$01,$00,$0C);
  1203. begin
  1204.   InvokeMethod(DispInfo, nil);
  1205. end;
  1206.  
  1207. procedure TNNTP.GetArticleHeaders;
  1208. const
  1209.   DispInfo: array[0..10] of Byte = ($0A,$00,$00,$00,$00,$01,$03,$00,$08,$0C,$0C);
  1210. begin
  1211.   InvokeMethod(DispInfo, nil);
  1212. end;
  1213.  
  1214. procedure TNNTP.GetArticleByArticleNumber;
  1215. const
  1216.   DispInfo: array[0..8] of Byte = ($0B,$00,$00,$00,$00,$01,$01,$00,$0C);
  1217. begin
  1218.   InvokeMethod(DispInfo, nil);
  1219. end;
  1220.  
  1221. procedure TNNTP.GetArticleByMessageID;
  1222. const
  1223.   DispInfo: array[0..8] of Byte = ($0C,$00,$00,$00,$00,$01,$01,$00,$08);
  1224. begin
  1225.   InvokeMethod(DispInfo, nil);
  1226. end;
  1227.  
  1228. procedure TNNTP.GetHeaderByArticleNumber;
  1229. const
  1230.   DispInfo: array[0..8] of Byte = ($0D,$00,$00,$00,$00,$01,$01,$00,$0C);
  1231. begin
  1232.   InvokeMethod(DispInfo, nil);
  1233. end;
  1234.  
  1235. procedure TNNTP.GetHeaderByMessageID;
  1236. const
  1237.   DispInfo: array[0..8] of Byte = ($0E,$00,$00,$00,$00,$01,$01,$00,$08);
  1238. begin
  1239.   InvokeMethod(DispInfo, nil);
  1240. end;
  1241.  
  1242. procedure TNNTP.GetBodyByArticleNumber;
  1243. const
  1244.   DispInfo: array[0..8] of Byte = ($0F,$00,$00,$00,$00,$01,$01,$00,$0C);
  1245. begin
  1246.   InvokeMethod(DispInfo, nil);
  1247. end;
  1248.  
  1249. procedure TNNTP.GetBodyByMessageID;
  1250. const
  1251.   DispInfo: array[0..8] of Byte = ($10,$00,$00,$00,$00,$01,$01,$00,$08);
  1252. begin
  1253.   InvokeMethod(DispInfo, nil);
  1254. end;
  1255.  
  1256. procedure TNNTP.GetStatByArticleNumber;
  1257. const
  1258.   DispInfo: array[0..8] of Byte = ($11,$00,$00,$00,$00,$01,$01,$00,$0C);
  1259. begin
  1260.   InvokeMethod(DispInfo, nil);
  1261. end;
  1262.  
  1263. procedure TNNTP.GetOverviewFormat;
  1264. const
  1265.   DispInfo: array[0..7] of Byte = ($12,$00,$00,$00,$00,$01,$00,$00);
  1266. begin
  1267.   InvokeMethod(DispInfo, nil);
  1268. end;
  1269.  
  1270. procedure TNNTP.GetOverview;
  1271. const
  1272.   DispInfo: array[0..9] of Byte = ($13,$00,$00,$00,$00,$01,$02,$00,$0C,$0C);
  1273. begin
  1274.   InvokeMethod(DispInfo, nil);
  1275. end;
  1276.  
  1277. procedure TNNTP.ListGroups;
  1278. const
  1279.   DispInfo: array[0..7] of Byte = ($14,$00,$00,$00,$00,$01,$00,$00);
  1280. begin
  1281.   InvokeMethod(DispInfo, nil);
  1282. end;
  1283.  
  1284. procedure TNNTP.ListGroupDescriptions;
  1285. const
  1286.   DispInfo: array[0..7] of Byte = ($15,$00,$00,$00,$00,$01,$00,$00);
  1287. begin
  1288.   InvokeMethod(DispInfo, nil);
  1289. end;
  1290.  
  1291. procedure TNNTP.ListNewGroups;
  1292. const
  1293.   DispInfo: array[0..8] of Byte = ($16,$00,$00,$00,$00,$01,$01,$00,$0C);
  1294. begin
  1295.   InvokeMethod(DispInfo, nil);
  1296. end;
  1297.  
  1298. procedure TNNTP.Quit;
  1299. const
  1300.   DispInfo: array[0..7] of Byte = ($18,$00,$00,$00,$00,$01,$00,$00);
  1301. begin
  1302.   InvokeMethod(DispInfo, nil);
  1303. end;
  1304.  
  1305. function TNNTP.Get_Timeout;
  1306. const
  1307.   DispInfo: array[0..8] of Byte = ($FB,$01,$00,$00,$03,$02,$01,$00,$02);
  1308. begin
  1309.   InvokeMethod(DispInfo, @Result);
  1310. end;
  1311.  
  1312. procedure TNNTP.Set_Timeout;
  1313. const
  1314.   DispInfo: array[0..9] of Byte = ($FB,$01,$00,$00,$00,$04,$02,$00,$02,$03);
  1315. begin
  1316.   InvokeMethod(DispInfo, nil);
  1317. end;
  1318.  
  1319. procedure TNNTP.Set_EnableTimer;
  1320. const
  1321.   DispInfo: array[0..9] of Byte = ($01,$02,$00,$00,$00,$04,$02,$00,$02,$0B);
  1322. begin
  1323.   InvokeMethod(DispInfo, nil);
  1324. end;
  1325.  
  1326. { TPOP }
  1327.  
  1328. procedure TPOP.InitControlData;
  1329. const
  1330.   CEventDispIDs: array[0..13] of Integer = (
  1331.     $FFFFFDA0, $00000227, $00000228, $00000229, $0000022A, $0000022B,
  1332.     $0000022C, $000003F9, $000009A1, $000009A2, $000009A3, $000009A4,
  1333.     $000009A6, $000009A7);
  1334.   CControlData: TControlData = (
  1335.     ClassID: (
  1336.       D1:$B7FC356E;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1337.     EventIID: (
  1338.       D1:$B7FC356D;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1339.     EventCount: 14;
  1340.     EventDispIDs: @CEventDispIDs;
  1341.     LicenseKey: nil;
  1342.     Flags: $00000000);
  1343. begin
  1344.   ControlData := @CControlData;
  1345. end;
  1346.  
  1347. procedure TPOP.AboutBox;
  1348. const
  1349.   DispInfo: array[0..7] of Byte = ($D8,$FD,$FF,$FF,$00,$01,$00,$00);
  1350. begin
  1351.   InvokeMethod(DispInfo, nil);
  1352. end;
  1353.  
  1354. procedure TPOP.Cancel;
  1355. const
  1356.   DispInfo: array[0..7] of Byte = ($08,$02,$00,$00,$00,$01,$00,$00);
  1357. begin
  1358.   InvokeMethod(DispInfo, nil);
  1359. end;
  1360.  
  1361. procedure TPOP.Connect;
  1362. const
  1363.   DispInfo: array[0..9] of Byte = ($09,$02,$00,$00,$00,$01,$02,$00,$0C,$0C);
  1364. begin
  1365.   InvokeMethod(DispInfo, nil);
  1366. end;
  1367.  
  1368. procedure TPOP.Authenticate;
  1369. const
  1370.   DispInfo: array[0..9] of Byte = ($62,$02,$00,$00,$00,$01,$02,$00,$0C,$0C);
  1371. begin
  1372.   InvokeMethod(DispInfo, nil);
  1373. end;
  1374.  
  1375. procedure TPOP.GetDoc;
  1376. const
  1377.   DispInfo: array[0..10] of Byte = ($EC,$03,$00,$00,$00,$01,$03,$00,$0C,$0C,$0C);
  1378. begin
  1379.   InvokeMethod(DispInfo, nil);
  1380. end;
  1381.  
  1382. procedure TPOP.MessageSize;
  1383. const
  1384.   DispInfo: array[0..8] of Byte = ($98,$09,$00,$00,$00,$01,$01,$00,$02);
  1385. begin
  1386.   InvokeMethod(DispInfo, nil);
  1387. end;
  1388.  
  1389. procedure TPOP.RetrieveMessage;
  1390. const
  1391.   DispInfo: array[0..8] of Byte = ($99,$09,$00,$00,$00,$01,$01,$00,$02);
  1392. begin
  1393.   InvokeMethod(DispInfo, nil);
  1394. end;
  1395.  
  1396. procedure TPOP.Delete;
  1397. const
  1398.   DispInfo: array[0..8] of Byte = ($9A,$09,$00,$00,$00,$01,$01,$00,$02);
  1399. begin
  1400.   InvokeMethod(DispInfo, nil);
  1401. end;
  1402.  
  1403. procedure TPOP.Reset;
  1404. const
  1405.   DispInfo: array[0..7] of Byte = ($9B,$09,$00,$00,$00,$01,$00,$00);
  1406. begin
  1407.   InvokeMethod(DispInfo, nil);
  1408. end;
  1409.  
  1410. procedure TPOP.Last;
  1411. const
  1412.   DispInfo: array[0..7] of Byte = ($9C,$09,$00,$00,$00,$01,$00,$00);
  1413. begin
  1414.   InvokeMethod(DispInfo, nil);
  1415. end;
  1416.  
  1417. procedure TPOP.Noop;
  1418. const
  1419.   DispInfo: array[0..7] of Byte = ($97,$09,$00,$00,$00,$01,$00,$00);
  1420. begin
  1421.   InvokeMethod(DispInfo, nil);
  1422. end;
  1423.  
  1424. procedure TPOP.TopMessage;
  1425. const
  1426.   DispInfo: array[0..8] of Byte = ($9D,$09,$00,$00,$00,$01,$01,$00,$02);
  1427. begin
  1428.   InvokeMethod(DispInfo, nil);
  1429. end;
  1430.  
  1431. procedure TPOP.Quit;
  1432. const
  1433.   DispInfo: array[0..7] of Byte = ($9E,$09,$00,$00,$00,$01,$00,$00);
  1434. begin
  1435.   InvokeMethod(DispInfo, nil);
  1436. end;
  1437.  
  1438. procedure TPOP.RefreshMessageCount;
  1439. const
  1440.   DispInfo: array[0..7] of Byte = ($C4,$09,$00,$00,$00,$01,$00,$00);
  1441. begin
  1442.   InvokeMethod(DispInfo, nil);
  1443. end;
  1444.  
  1445. function TPOP.Get_Timeout;
  1446. const
  1447.   DispInfo: array[0..8] of Byte = ($FB,$01,$00,$00,$03,$02,$01,$00,$02);
  1448. begin
  1449.   InvokeMethod(DispInfo, @Result);
  1450. end;
  1451.  
  1452. procedure TPOP.Set_Timeout;
  1453. const
  1454.   DispInfo: array[0..9] of Byte = ($FB,$01,$00,$00,$00,$04,$02,$00,$02,$03);
  1455. begin
  1456.   InvokeMethod(DispInfo, nil);
  1457. end;
  1458.  
  1459. procedure TPOP.Set_EnableTimer;
  1460. const
  1461.   DispInfo: array[0..9] of Byte = ($01,$02,$00,$00,$00,$04,$02,$00,$02,$0B);
  1462. begin
  1463.   InvokeMethod(DispInfo, nil);
  1464. end;
  1465.  
  1466. { TSMTP }
  1467.  
  1468. procedure TSMTP.InitControlData;
  1469. const
  1470.   CEventDispIDs: array[0..12] of Integer = (
  1471.     $FFFFFDA0, $00000227, $00000228, $00000229, $0000022A, $0000022B,
  1472.     $0000022C, $000003F8, $0000012C, $0000012D, $0000012E, $0000012F,
  1473.     $00000130);
  1474.   CControlData: TControlData = (
  1475.     ClassID: (
  1476.       D1:$B7FC3573;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1477.     EventIID: (
  1478.       D1:$B7FC3572;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1479.     EventCount: 13;
  1480.     EventDispIDs: @CEventDispIDs;
  1481.     LicenseKey: nil;
  1482.     Flags: $00000000);
  1483. begin
  1484.   ControlData := @CControlData;
  1485. end;
  1486.  
  1487. procedure TSMTP.AboutBox;
  1488. const
  1489.   DispInfo: array[0..7] of Byte = ($D8,$FD,$FF,$FF,$00,$01,$00,$00);
  1490. begin
  1491.   InvokeMethod(DispInfo, nil);
  1492. end;
  1493.  
  1494. procedure TSMTP.Cancel;
  1495. const
  1496.   DispInfo: array[0..7] of Byte = ($08,$02,$00,$00,$00,$01,$00,$00);
  1497. begin
  1498.   InvokeMethod(DispInfo, nil);
  1499. end;
  1500.  
  1501. procedure TSMTP.Connect;
  1502. const
  1503.   DispInfo: array[0..9] of Byte = ($09,$02,$00,$00,$00,$01,$02,$00,$0C,$0C);
  1504. begin
  1505.   InvokeMethod(DispInfo, nil);
  1506. end;
  1507.  
  1508. procedure TSMTP.SendDoc;
  1509. const
  1510.   DispInfo: array[0..12] of Byte = ($ED,$03,$00,$00,$00,$01,$05,$00,$0C,$0C,$0C,$0C,$0C);
  1511. begin
  1512.   InvokeMethod(DispInfo, nil);
  1513. end;
  1514.  
  1515. procedure TSMTP.Reset;
  1516. const
  1517.   DispInfo: array[0..7] of Byte = ($C8,$00,$00,$00,$00,$01,$00,$00);
  1518. begin
  1519.   InvokeMethod(DispInfo, nil);
  1520. end;
  1521.  
  1522. procedure TSMTP.Verify;
  1523. const
  1524.   DispInfo: array[0..8] of Byte = ($C9,$00,$00,$00,$00,$01,$01,$00,$08);
  1525. begin
  1526.   InvokeMethod(DispInfo, nil);
  1527. end;
  1528.  
  1529. procedure TSMTP.Expand;
  1530. const
  1531.   DispInfo: array[0..8] of Byte = ($CA,$00,$00,$00,$00,$01,$01,$00,$08);
  1532. begin
  1533.   InvokeMethod(DispInfo, nil);
  1534. end;
  1535.  
  1536. procedure TSMTP.Help;
  1537. const
  1538.   DispInfo: array[0..8] of Byte = ($CB,$00,$00,$00,$00,$01,$01,$00,$0C);
  1539. begin
  1540.   InvokeMethod(DispInfo, nil);
  1541. end;
  1542.  
  1543. procedure TSMTP.Noop;
  1544. const
  1545.   DispInfo: array[0..7] of Byte = ($CC,$00,$00,$00,$00,$01,$00,$00);
  1546. begin
  1547.   InvokeMethod(DispInfo, nil);
  1548. end;
  1549.  
  1550. procedure TSMTP.Quit;
  1551. const
  1552.   DispInfo: array[0..7] of Byte = ($CD,$00,$00,$00,$00,$01,$00,$00);
  1553. begin
  1554.   InvokeMethod(DispInfo, nil);
  1555. end;
  1556.  
  1557. function TSMTP.Get_Timeout;
  1558. const
  1559.   DispInfo: array[0..8] of Byte = ($FB,$01,$00,$00,$03,$02,$01,$00,$02);
  1560. begin
  1561.   InvokeMethod(DispInfo, @Result);
  1562. end;
  1563.  
  1564. procedure TSMTP.Set_Timeout;
  1565. const
  1566.   DispInfo: array[0..9] of Byte = ($FB,$01,$00,$00,$00,$04,$02,$00,$02,$03);
  1567. begin
  1568.   InvokeMethod(DispInfo, nil);
  1569. end;
  1570.  
  1571. procedure TSMTP.Set_EnableTimer;
  1572. const
  1573.   DispInfo: array[0..9] of Byte = ($01,$02,$00,$00,$00,$04,$02,$00,$02,$0B);
  1574. begin
  1575.   InvokeMethod(DispInfo, nil);
  1576. end;
  1577.  
  1578. { TTCP }
  1579.  
  1580. procedure TTCP.InitControlData;
  1581. const
  1582.   CEventDispIDs: array[0..6] of Integer = (
  1583.     $FFFFFDA0, $0000041B, $0000047F, $00000480, $00000483, $00000481,
  1584.     $00000482);
  1585.   CControlData: TControlData = (
  1586.     ClassID: (
  1587.       D1:$B7FC3584;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1588.     EventIID: (
  1589.       D1:$B7FC3583;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1590.     EventCount: 7;
  1591.     EventDispIDs: @CEventDispIDs;
  1592.     LicenseKey: nil;
  1593.     Flags: $00000000);
  1594. begin
  1595.   ControlData := @CControlData;
  1596. end;
  1597.  
  1598. procedure TTCP.AboutBox;
  1599. const
  1600.   DispInfo: array[0..7] of Byte = ($D8,$FD,$FF,$FF,$00,$01,$00,$00);
  1601. begin
  1602.   InvokeMethod(DispInfo, nil);
  1603. end;
  1604.  
  1605. procedure TTCP.Connect;
  1606. const
  1607.   DispInfo: array[0..9] of Byte = ($09,$02,$00,$00,$00,$01,$02,$00,$0C,$0C);
  1608. begin
  1609.   InvokeMethod(DispInfo, nil);
  1610. end;
  1611.  
  1612. procedure TTCP.Listen;
  1613. const
  1614.   DispInfo: array[0..7] of Byte = ($4E,$04,$00,$00,$00,$01,$00,$00);
  1615. begin
  1616.   InvokeMethod(DispInfo, nil);
  1617. end;
  1618.  
  1619. procedure TTCP.Accept;
  1620. const
  1621.   DispInfo: array[0..8] of Byte = ($4F,$04,$00,$00,$00,$01,$01,$00,$03);
  1622. begin
  1623.   InvokeMethod(DispInfo, nil);
  1624. end;
  1625.  
  1626. procedure TTCP.SendData;
  1627. const
  1628.   DispInfo: array[0..8] of Byte = ($F4,$03,$00,$00,$00,$01,$01,$00,$0C);
  1629. begin
  1630.   InvokeMethod(DispInfo, nil);
  1631. end;
  1632.  
  1633. procedure TTCP.GetData;
  1634. const
  1635.   DispInfo: array[0..10] of Byte = ($F3,$03,$00,$00,$00,$01,$03,$00,$8C,$0C,$0C);
  1636. begin
  1637.   InvokeMethod(DispInfo, nil);
  1638. end;
  1639.  
  1640. procedure TTCP.PeekData;
  1641. const
  1642.   DispInfo: array[0..10] of Byte = ($50,$04,$00,$00,$00,$01,$03,$00,$8C,$0C,$0C);
  1643. begin
  1644.   InvokeMethod(DispInfo, nil);
  1645. end;
  1646.  
  1647. procedure TTCP.Close;
  1648. const
  1649.   DispInfo: array[0..7] of Byte = ($51,$04,$00,$00,$00,$01,$00,$00);
  1650. begin
  1651.   InvokeMethod(DispInfo, nil);
  1652. end;
  1653.  
  1654. { TUDP }
  1655.  
  1656. procedure TUDP.InitControlData;
  1657. const
  1658.   CEventDispIDs: array[0..1] of Integer = (
  1659.     $FFFFFDA0, $0000041B);
  1660.   CControlData: TControlData = (
  1661.     ClassID: (
  1662.       D1:$B7FC3587;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1663.     EventIID: (
  1664.       D1:$B7FC3586;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1665.     EventCount: 2;
  1666.     EventDispIDs: @CEventDispIDs;
  1667.     LicenseKey: nil;
  1668.     Flags: $00000000);
  1669. begin
  1670.   ControlData := @CControlData;
  1671. end;
  1672.  
  1673. procedure TUDP.AboutBox;
  1674. const
  1675.   DispInfo: array[0..7] of Byte = ($D8,$FD,$FF,$FF,$00,$01,$00,$00);
  1676. begin
  1677.   InvokeMethod(DispInfo, nil);
  1678. end;
  1679.  
  1680. procedure TUDP.SendData;
  1681. const
  1682.   DispInfo: array[0..8] of Byte = ($F4,$03,$00,$00,$00,$01,$01,$00,$0C);
  1683. begin
  1684.   InvokeMethod(DispInfo, nil);
  1685. end;
  1686.  
  1687. procedure TUDP.GetData;
  1688. const
  1689.   DispInfo: array[0..9] of Byte = ($F3,$03,$00,$00,$00,$01,$02,$00,$8C,$0C);
  1690. begin
  1691.   InvokeMethod(DispInfo, nil);
  1692. end;
  1693.  
  1694. procedure Register;
  1695. begin
  1696.   RegisterComponents('Internet', [TFTP, THTML, THTTP, TNNTP, TPOP, TSMTP, TTCP, TUDP]);
  1697. end;
  1698.  
  1699.  
  1700. end.
  1701.  
  1702.