Problem in Progress Bar [message #213551] |
Thu, 11 January 2007 04:17 |
emadbsb
Messages: 334 Registered: May 2005 Location: egypt
|
Senior Member |
|
|
Hii all
I created a progross bar
and it works fine
but i have a small problem
suppose that i am loading data on my screen form
and while the progress bar is working (e.g i reached 20%)
i change to another window when i return back to the screen
it stop the syncronysing operation and the data is loaded wihout affect on the progress bar and after the end of the operation the progress bar displays (100%)
this is the code that control the operation of the progress bar
Declare
Previous_Width Number(10,5);
tm_Name Varchar2(20);
Vcount1 number;
Vinc number;
vREMAINDER3 NUMBER;
COUNTER NUMBER := 0;
Begin
Vinc := round(Vcount1/100);
IF (MOD(:SYSTEM.CURSOR_RECORD,Vinc) = 0 ) THEN
Previous_Width := Get_Item_Property('Progress_Bar',Width);
If counter <= 100 Then
Set_Item_Property('Progress_Bar',Width, Previous_Width+ (Get_Item_Property('FRAME',Width)/100)));
:Position := counter || '%';
Counter := counter +1;
Synchronize;
End If;
END IF;
|
|
|
Re: Problem in Progress Bar [message #213575 is a reply to message #213551] |
Thu, 11 January 2007 05:42 |
|
Littlefoot
Messages: 21823 Registered: June 2005 Location: Croatia, Europe
|
Senior Member Account Moderator |
|
|
It seems that synchronizing is canceled when Forms window lost the focus.
Perhaps you could create a timer which would execute this code in a matter of a second or two (using WHEN-TIMER-EXPIRED trigger).
[Updated on: Thu, 11 January 2007 05:43] Report message to a moderator
|
|
|
|
|
|
|
|
Re: Problem in Progress Bar [message #214080 is a reply to message #213551] |
Sun, 14 January 2007 19:57 |
|
emadbsb wrote on Thu, 11 January 2007 10:17 |
i change to another window when i return back to the screen
it stop the syncronysing operation and the data is loaded wihout affect on the progress bar and after the end of the operation the progress bar displays (100%)
|
Even if you don't change window, you can still encounter that problem. Synchronize seems not working because the screen display hangs.. I believe it's because the process uses much of cpu resources. after the process, the computer can now refresh the screen so you see it displayed 100%.
|
|
|
Re: Problem in Progress Bar [message #214226 is a reply to message #214080] |
Mon, 15 January 2007 08:38 |
yogen
Messages: 39 Registered: October 2006 Location: UK
|
Member |
|
|
hi ,
I am testing this functionality....and i found that this behaviour is very random....sometimes this synchronization stops while sometimes it works fine...are you using any when-window-activated trigger.?
may be this problem is related to this trigger or some global variables which control the navigation condition of various screens.but currently i am not sure about this.
thanks,
Yogen.
[Updated on: Mon, 15 January 2007 08:41] Report message to a moderator
|
|
|
|