D:\UniGUI_1583 D12.2 (完整版 汉化 安装工具)\uniGUI\Demos\Desktop\AllFeaturesDemo\units\FormControlsProgressBar.pas

procedure TUniFormControlsProgressBar.UniButton1Click(Sender: TObject);
begin
  UniTimer1.Enabled := True;
end;

procedure TUniFormControlsProgressBar.UniTimer1Timer(Sender: TObject);
begin
   UniProgressBar1.Position := UniProgressBar1.Position + Random(10);
   UniLabel1.Caption := '% '+IntToStr(UniProgressBar1.Position);
   if UniProgressBar1.Position = UniProgressBar1.Max then
      UniLabel1.Caption := 'Loading Complete'
end;