Page 1 of 1

Refresh label

PostPosted: 04 May 2015 10:52
by etwoss
Hi

I have a setup like the demo nut with also a footerpanel
In this footerpanel i have a label that's needs to be updated. The information comes from one of the form being shown
I do not want a complete refresh however
How can this be done?

Eric

Re: Refresh label

PostPosted: 04 May 2015 11:02
by Alexander Bulei
Hi Eric,

Hard weekend? :D

Use IWCGJQLabel.AjaxReRender ;)

Best Regards.

Re: Refresh label

PostPosted: 04 May 2015 12:19
by etwoss
Hi

Yes , but also:

Method "RenderRegionAsync"is nly allowed in Ajax Processing"

Eric

Re: Refresh label

PostPosted: 12 May 2015 13:32
by etwoss
Hi

New situaton:

Code: Select all
    repeat
    begin
      UserName     := UserList[0];
      IWCGJQLabelEx1.TextEx.Text := UserName;
      IWCGJQLabelEx1.AjaxReRender();
      codesite.Send('IWCGJQLabelEx1.TextEx.Text', IWCGJQLabelEx1.TextEx.Text);

      TickCountStart := GetTickCount;
      TickCountEnd   := TickCountStart + (2000);

      while (TickCountStart < TickCountEnd) do
      begin
          TickCountStart  := GetTickCount;
       end;
    end;
    until (MailList.Count = 0 ) or (UserList.Count = 0);



In codesite i see IWCGJQLabelEx1.TextEx.Text changing but not on the form (which is a TIWCGJQFrame)
Can't you do a refresh during 1 event?
Why is the label not refreshed during the loop? Only the last one is displayed

I had it working with a TIWTimer when i was using forms but now i use Frames the timer does not work anymore so i need another solution.

Thanks for your help

Eric

Re: Refresh label

PostPosted: 13 May 2015 08:09
by etwoss
Hi

Solved it with events to my main form and use a timer there.

Eric

Re: Refresh label

PostPosted: 13 May 2015 09:30
by Alexander Bulei
Hi Eric,

Can't you do a refresh during 1 event?


No, you can't.
The server will send the response to client browser only after completes the event.

You need use timer for this purpose.

Best Regards.