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.
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.
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
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. |
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
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.
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,
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