Jump to content

trey

Members
  • Posts

    2
  • Joined

  • Last visited

Contact Methods

  • ICQ
    558209966

Profile Information

  • Gender
    Male
  • Location
    49.422460,26.984458
  • Interests
    Delphi, Girls, Beer

trey's Achievements

Newbie

Newbie (1/4)

0

Reputation

  1. Thanks for the link. but! Why should I write "bikes"? why asynchronous operation can not be achieved by the component itself? why methods Repaint, Refresh, in components when it does not work ?
  2. Put on form UniPanel1: TUniPanel; UniButton1: TUniButton; UniProgressBar1: TUniProgressBar; UniLabel1: TUniLabel; Run on WebBrowser uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs, uniGUITypes, uniGUIAbstractClasses, uniGUIClasses, uniGUIForm, uniLabel, uniProgressBar, uniButton, uniGUIBaseClasses, uniPanel; type TMainForm = class(TUniForm) UniPanel1: TUniPanel; UniButton1: TUniButton; UniProgressBar1: TUniProgressBar; UniLabel1: TUniLabel; procedure UniFormCreate(Sender: TObject); procedure UniButton1Click(Sender: TObject); private { Private declarations } public { Public declarations } end; function MainForm: TMainForm; implementation {$R *.dfm} uses uniGUIVars, MainModule, ServerModule, uniGUIServer; function MainForm: TMainForm; begin Result := TMainForm(UniMainModule.GetFormInstance(TMainForm)); end; procedure TMainForm.UniButton1Click(Sender: TObject); var i:integer; begin UniProgressBar1.Max:=100; UniPanel1.Visible:=true; // 1. why does not work? for i:=0 to 100 do begin sleep(10); UniLabel1.Text:=inttostr(i); // 2. why does not work? UniProgressBar1.Position:=i; // 3. why does not work? Application.ProcessMessages; // 4. why does not work? UniProgressBar1.Refresh; // 5. why does not work? UniProgressBar1.RePaint; // 6. why does not work? end; UniPanel1.Visible:=false; end; procedure TMainForm.UniFormCreate(Sender: TObject); begin UniServerModule.MainFormDisplayMode:=mfPage; UniPanel1.Visible:=false; end; initialization RegisterMainFormClass(TMainForm); end. I even tried to run the UniProgressBar1.Position in a new threads , but webform is dead when the cycle runs.
×
×
  • Create New...