Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/delphi/9.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/javascript/398.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Delphi TDownloadURL.AfterDownload的正确参数列表是什么_Delphi_Delphi Xe4 - Fatal编程技术网

Delphi TDownloadURL.AfterDownload的正确参数列表是什么

Delphi TDownloadURL.AfterDownload的正确参数列表是什么,delphi,delphi-xe4,Delphi,Delphi Xe4,如何分配iDownloadURL.AfterDownload:=AfterDownloadLicense;TNotifyEvent?您可以在中查找,甚至可以使用IDE编辑器在System.Classes.pas中查找TNotifyEvent声明: { Download the license file with expiration date } iDownloadURL := TDownloadURL.Create(nil); try iBaseURL := DomainNam

如何分配iDownloadURL.AfterDownload:=AfterDownloadLicense;TNotifyEvent?

您可以在中查找,甚至可以使用IDE编辑器在
System.Classes.pas中查找
TNotifyEvent
声明:

{ Download the license file with expiration date }
  iDownloadURL := TDownloadURL.Create(nil);
  try
    iBaseURL := DomainName1.Text;
    iDownloadURL.FileName := ATempFilesFolder + UserName1.Text + 'lcn';
    iDownloadURL.url := iBaseURL;
    iDownloadURL.OnDownloadProgress := URL_OnDownloadProgress;
    iDownloadURL.AfterDownload := AfterDownloadLicense; {License is validated here }
    iDownloadURL.ExecuteTarget(nil);
  finally
    { If a connection fails then a dialog will appear that shows an error.
    If running in the ide then an exception box will appear, Press the continue
    button... then the message will be shown }
    iDownloadURL.Free;
    StatusBar1.SimpleText := 'Failed validation connection...';
    Form1.StatusBar1.SimpleText := 'Failed validation connection...';
  end;

procedure TFormDomainSettings.AfterDownloadLicense;
begin
  if not FileExists(ATempFilesFolder + UserName1.Text + 'lcn') then
  begin
    TaskMessageDlg('Error Downloading License File',
      'The license file could not be downloaded.', mtWarning, [mbOk], 0);
  end
  else
  begin
    ValidateLicense;
  end;
end;
话虽如此,
AfterDownloadLicense()
需要如下所示:

TNotifyEvent = procedure(Sender: TObject) of object;

很抱歉我想我早就试过了,但它无法编译。
procedure TFormDomainSettings.AfterDownloadLicense(Sender: TObject);