Author Archives: Manish Pandey

How to Set current row of ADF table (View Object)

Sometimes user need to set current row in ADF table through programming. There is an Operation available on all View Object Instance inside Data Control.     So I am describing steps how to achieve this. First Create Action Binding for “setCurrentRowWithKeyValue” operation. After that create a method on ManagedBean to set Current Row. BindingContext bindingctx = BindingContext.getCurrent(); BindingContainer binding ... Read More »

ADF: Undo Current Row Changes in table.

Today, I am going to share a very interesting tutorial. Sometimes user need to undo all changes performed in only selected table row and display the older values which exists in database. So how to perform this task. If you are using “RollBack” operation, it reverts all changes performed in table. But if you want to keep all changes but ... Read More »

Consuming Web Service using ADF Web Service Data Control

Web Service is a client server application that communicate over WWW (World Wide Web) Http. Basically web service allows enterprises to expose business functionality irrespective of platform, language of application because business functionality exposed in such a way  composed of standard XML constructs that can be recognized and used by other applications. ADF have functionality to consume External Web Service ... Read More »

How to check whether ADF table row is modified or not.

Sometimes we need to know whether any row of ADF table is modified or not using managed bean. Here’s a quick solution to find whether ADF table rows are modified or not. There is a method in oracle.jbo.Transaction class called isDirty()  used to find row is modified or not. BindingContainer binding=bindingctx.getCurrentBindingsEntry(); DCBindingContainer bindingsImpl = (DCBindingContainer) binding; DCIteratorBinding dciter = bindingsImpl.findIteratorBinding(“iterName”); ViewObject ... Read More »

ADF Tricks

Some solution are too small to write blog or article, today I will explain some common code which are required while creating application using ADF technology. 1. Get View Object Instance in Managed Bean. BindingContext bindingctx=BindingContext.getCurrent(); BindingContainer binding=bindingctx.getCurrentBindingsEntry(); DCBindingContainer bindingsImpl = (DCBindingContainer) binding; DCIteratorBinding dciter = bindingsImpl.findIteratorBinding(IteratorName); ViewObject vo=dciter.getViewObject(); 2. Redirect Page. FacesContext.getCurrentInstance().getExternalContext().redirect(“url”); 3. Gets Session Object value using Groovy ... Read More »

Disable future Date on ADF “inputDate” Component

Sometimes we need to disable future date on ADF inputDate Component so that, a user is unable to select date after the current date. For this purpose we can use ADF inputDate component MaxValue property. Here’s a small step by step tutorial to achieve this requirement. Step1:- drag-drop ADF inputDate component on jspx page from component palette. Step2:- create following ... Read More »

Using Method Call Activity to open form on Insert Mode

This is very common scenario where a user wants to execute some code before the page loads. For this purpose, ADF Framework provides Method Call Activity. Method Call Activity creates a method on your managed bean which is being called first and after that, the jspx page loads. In my example I have created a simple form using employees table ... Read More »

ADF Table: Select multiple rows using check box.

Today I’m going to explain very common case of selecting multiple rows in ADF table using checkboxes. This is very common requirement where user wants to select multiple rows using check box. Here I’m using hr schema employees table.   Step1: create Entity Object and View Object using Employees table. Step2: Create transient attribute Boolean type on Employees View Object. ... Read More »

ADF: Custom Error Handler to Display Custom Message to User

Sometimes user wants to display custom error message instead of default message. For such cases ADF framework provides a way to create custom error handler class which extends default DCErrorHandlerImpl class. You are not required to write any code to register your custom exception handler class. Instead, you’ve to select the root node of the DataBindings.cpx files in the Structure ... Read More »