Skip to main content

Show Page Loader (Progress) when Page Busy, Delay (Long Execution Time).

As we know some actions can take long time to return back the response, in this case the user may do not know what happens at this time, so we need to show or display some indicators that reflect these delays or executions to the user.

To get start we need to know some JavaScript.

Inside the target page add popup component and design your own style as you need, I prefer use animated image to reflect the real functionality of loader.


Now you need to add the following script inside your page using <af:resources> tag, this script will open the popup by id, the yellow color in the images show that.


Inside the page add command button to execute your action, this button contains <af:clientListener> component to invoke function in the JavaScript when start executing the action.

Button will be execute run method and open popup by invoking JavaScript function.

To show the loader we need to make page delay, for test I will use the following code, but in general this will happens when you come to invoke your business executions.


Finally, run your page and test it, the output will be like :


You can change the design by changing animated image in the popup :



You can download the sample source from here - Long Execution Time ( zip ) - JDev 11.1.2.4

Comments

Sudipto Desmukh said…
Hi ,
Any particular reason you are using an af:activeImage for the icon ?
AFAIK , we use this when showing active data which needs to be configured.
Alaa Bani Taha said…
Hi Sudipto Desmukh,

In my case each application has it own loading image and this image assigned at run time, in this example no need to af:activeImage just forget to change it.

Regards,
Unknown said…
The History of the Casino - One of the Most Popular Casinos
A relative newcomer to the world 바카라사이트 of online gambling, Wynn Las Vegas casinosites.one opened its doors titanium flat iron to 바카라 사이트 a new audience of over 600,000 in 2017. This was the 바카라 first casino
Anonymous said…
Filament-wise, it’s PLA only, which is greatest choice|the only option|your CNC machining finest option} for newbies. The Mini Delta V2 is nice for newbies due to its bargain-basement value, simple setup, and easy operation. Although its output in our checks was practically misprint-free, print high quality was unspectacular. That, and a relatively small construct space, makes it a less-than-optimal alternative for intermediate—let alone expert—users.

Popular posts from this blog

Using Database Sequence in ADF BC.

You can use database sequence in ADF BC in different ways and I will explain some of these ways. 1 - Override Create() method in the entity object :   t his solution depends on create operation, mean when you create new row then the database sequence generate new value, in the entity object select java, then click on edit icon ,  and check  Create Method . Now inside the  EntityObjectImpl  go to the  create()  method and add the following code,  make sure your key attribute data type is  compatible  with sequence return value. 2 - Using Groovy Expression :  in this way we need to set the key attribute  with   default value and this value will be expression, this expression will get the sequence value from database sequence, make sure to pick Expression choice. The expression value will be like  Also you can write your own method that call database sequence inside the  EntityObjectImpl  and call it using groovy expression, but you make sure your method return

Creating a wlfullclient.jar for client applications ( Weblogic 10.3.6 )

Do the following steps under windows command shell : 1 -  Open the Weblogic server library :       cd   {fmw_home} \wlserver_10.3\server\lib 2 - Execute the following command :      {fmw_home}\wlserver_10.3\server\lib >   {java_home} \bin\java  -jar wljarbuilder.jar 3 - This command will generate  wlfullclient.jar , You can add it to your client application classpath .