During the application development in ADF, the most common problem that we encounter when our application is deployed on server is the problem of refresh. That means you expect a component to refresh on some action but still it doesn't happens.
This problem comes into picture in a big size application that uses many other applications or many taskflows are being called into it.I dont exaclty know why this problem comes into focus, but its some kind of 'id' problem of UIcomponent.
So, here are some of the solution if the above problem comes into picture.
This problem comes into picture in a big size application that uses many other applications or many taskflows are being called into it.I dont exaclty know why this problem comes into focus, but its some kind of 'id' problem of UIcomponent.
So, here are some of the solution if the above problem comes into picture.
- The easiest way to give partial trigger to a UIComponent is to go into the properties menu in the property inspector and simply choose the component id you want to select. So whenever the selected UIcomponents will have a change, the UIComponent on which partial refresh is given is refreshed.
- Sometimes it happens that even after giving partial trigger on the UIComponent the Component is not been refreshed.So, you can try to refresh the component from the bean using java code.
AdfFacesContext.getCurrentInstance().addPartialTarget(UIComponent);
Here 'UIComponent' is the binding of the UIComponent on the page into the bean. - Sometimes the above two methods fail.After using the above two techniques also the field is not being refreshed. Then you can use the ResetUtil class for resetting the fields.
For using ResetUtil you have to import the given class:import oracle.adf.view.rich.util.ResetUtils;
And to use it on the page :
ResetUtils.reset(UIComponent);
- After using the above methods if Still the problem exists. Then if you are using model in your application, then you have to perform "execute" on the used ViewObject.
- Still if the problem persists, then perform "Rollback" after the "Commit" operation.
- Still if the problem exists, please drop your case in the comment box.. :)
i have a popup which has a image which can be changed through file component.
ReplyDeleteIt works fine with step 2, i.e. as soon as i change image it is visible in the popup.
But when i put some validation in the EO the image began to broke :(. can u tell the best way to refresh it . I tried till step 3 as cant perform 5 as it requires Commit and I cant do so :(
hello aakar,
ReplyDeleteWhat validation did you implement in the EO, please specify.
Are you sure the validation is working fine??
Hey Amaan thanks for reply the validation was having problem . which I resolved its working fine .
ReplyDeleteThanks for HELP !!
since add 12c use the component. Much more flexible and always work (for me)
ReplyDeletehi aman,
ReplyDeleteI'm using <af:menu. For all the commandmenuItems with type = check, the expression for property 'selected' is coming as true, but the checkbox is not getting ticked.
I have a commandMenuItem with label Showall whose function is to check all the other items in the menu.
The issue occurs when i first uncheck an item and then click on showAll. The item should be checked but its not.
My spouse and I love your blog and find almost all of your posts to be just what I’m looking for. Appreciating the persistence you put into your blog and the detailed information you provide. I found another one blog like you Oracle ADF.Actually I was looking for the same information on internet for Oracle Application Development Framework and came across your blog. I am impressed by the information that you have on this blog. Thanks once more for all the details.
ReplyDeleteI need to execute one method in bean whenever user clicks on browser refresh or f5.
ReplyDelete