Showing posts with label ADF Navigate Programmatically ControlFlow. Show all posts
Showing posts with label ADF Navigate Programmatically ControlFlow. Show all posts

Sunday, December 26, 2010

How to navigate programmatically using ControlFlow Case.

There are times when we wish to navigate from code instead of using the ‘Action’ property of UI component and at same time we like to use the ControlFlow cases defined in the taskflow. Well if you wish to do that you can use handleNavigation method from NavigationHandler class in javax.faces.application package.

Here is the sample:
            NavigationHandler  nvHndlr = FacesContext.getCurrentInstance().getApplication().getNavigationHandler();
            nvHndlr.handleNavigation(FacesContext.getCurrentInstance(), null, "PROVIDE_CONTROL_FLOW_CASE_NAME");