Create a binding for the popUp in the backing bean and use the following snippet to launch it programmatically
CaptiveCode
Hope you find this helpful! Please share your feedback below.
CaptiveCode
<managed-bean id="__1">
<managed-bean-name id="__243">RequestBean</managed-bean-name>
<managed-bean-class id="__244">ui.bean.RequestBean</managed-bean-class>
<managed-bean-scope id="__245">request</managed-bean-scope>
</managed-bean>
<managed-bean id="__2">
<managed-bean-name id="__248">BackingBean</managed-bean-name>
<managed-bean-class id="__246">ui.bean.BackingBean</managed-bean-class>
<managed-bean-scope id="__247">backingBean</managed-bean-scope>
</managed-bean>
package ui.bean;
import oracle.adf.view.rich.component.rich.nav.RichCommandToolbarButton;
public class BackingBean {
private RichButton submitBtn;
public void setSubmitBtn(RichButton submitBtn) {
this.submitBtn = submitBtn;
}
public RichButton getSubmitBtn() {
return submitBtn;
}
}
RequestBean Definition:package ui.bean;
import javax.el.ELContext;
import javax.faces.context.FacesContext;
import javax.faces.event.ActionEvent;
public class RequestBean {
public BackingBean getBackingBean() {
FacesContext fctx = FacesContext.getCurrentInstance();
ELContext context = fctx.getELContext();
BackingBean backingBean =
(BackingBean) fctx.getApplication().getExpressionFactory()
.createValueExpression(context,"#{backingBeanScope.BackingBean}",BackingBean.class)
.getValue(context);
return backingBean;
}
public void enableSubmit(ActionEvent actionEvent) {
/* Invoke BackingBean method to enable/disable Submit Button */
getBackingBean().getSubmitBtn().setDisabled(false);
}
}

public void executeInvoiceVOCriteria(String invoiceNum, String poNum){
ViewObjectImpl vo = getInvoiceVO1();
ViewCriteria vc = vo.getViewCriteria("InvoiceVOCriteria");
vo.applyViewCriteria(vc);
vo.setNamedWhereClauseParam("p_inv_num", invoiceNum);
vo.setNamedWhereClauseParam("p_po_num", poNum);
vo.executeQuery();
}
<persistence version="2.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://java.sun.com/xml/ns/persistence"
xsi:schemalocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd">
<persistence-unit name="Sample" transaction-type="JTA">
<description>Attribute Data Store</description>
<provider>org.eclipse.persistence.jpa.PersistenceProvider</provider>
<jta-data-source>jdbc/SampleDataSource</jta-data-source>
<properties>
<property name="toplink.logging.level" value="INFO">
</property></properties>
</persistence-unit>
</persistence>
public void processFormRequest(OAPageContext pageContext, OAWebBean webBean) {
super.processFormRequest(pageContext, webBean);
if (pageContext.getParameter("Go") != null) {
// form:APPLICATION_SHORT_NAME:RESPONSIBILITY_KEY:DATA_GROUP_NAME:FORM_FUNCTION_NAME
String destination = "form:FND:APPLICATION_DEVELOPER:STANDARD:FND_FNDPOMPO";
//Invoke the Form
pageContext.forwardImmediatelyToForm(destination);
}
}
String destination = "form:PO:PURCHASING_OPERATIONS_AIG:STANDARD:PO_POXPOEPO";
/**
* Parameters:
* PO_HEADER_ID
* = poHeaderId => This is the document ID
*
* ACCESS_LEVEL_CODE
* = MODIFY => This indicates to open the form in edit mode
*
* POXPOEPO_CALLING_FORM
* = OAF => This is calling function name.
* If your OAF page is registered as a function,
* provide the function short name here
*
* G_QUERY_FIND
* = FALSE
*
*/
String destination = "form:PO:PURCHASING_OPERATIONS_AIG:STANDARD:PO_POXPOEPO:"
+ "PO_HEADER_ID=\"" + poHeaderID
+ "\" " + "ACCESS_LEVEL_CODE=\"MODIFY\" "
+ "POXPOEPO_CALLING_FORM=\"OAF\" "
+ "G_QUERY_FIND=\"FALSE\"";
pageContext.forwardImmediatelyToForm(destination);
// 1. Get Date from Calendar int year=2016; int month=1; int date=1; Calendar cal = Calendar.getInstance(); cal.set(year, month, date); java.util.Date utilDate = cal.getTime(); // 2. Convert java.util.Date to java.sql.Date java.util.Date utilDate = new java.util.Date(); java.sql.Date sqlDate = new java.sql.Date(utilDate.getTime()); // 3. Convert java.sql.Date to oracle.jbo.domain.Date java.sql.Date sqlDate = new java.sql.Date(); new jbo.domain.Date(sqlDate); /* To get current date & time in jbo.domain.Date */ java.util.Date utilDate = new java.util.Date(); java.sql.Date sqlDate = new java.sql.Date(utilDate.getTime()); oracle.jbo.domain.Date jboDate = new oracle.jbo.domain.Date(sqlDate); // 4. Convert java.util.Date to java.sql.Timestamp java.util.Date utilDate = new java.util.Date(); java.sql.Timestamp timestamp_now = new java.sql.Timestamp(utilDate.getTime())
//Create HashMap to include destination page parameters
HashMap hm = new HashMap();
hm.put("poNumber",poNumber);
hm.put("pMode","createMemo");
//Forward to destination page
pageContext.setForwardURL(
"OA.jsp?page=/xxcc/oracle/apps/ar/demo/webui/myDemoPG", // Path to the destination page
null, // No need to specify with KEEP_MENU_CONTEXT
OAWebBeanConstants.KEEP_MENU_CONTEXT, // No change in the menu context. Keep same as source page
null, // No need to specify with KEEP_MENU_CONTEXT
hm, // HashMap with page parameter
true, //Retain AM state.
OAWebBeanConstants.ADD_BREAD_CRUMB_YES, //Show breadcrumbs
OAWebBeanConstants.IGNORE_MESSAGES //Ignore any messages
);
/* Use the following snippet in the Application Module (AM) */
OAViewObjectImpl vo = this.getMyDummyVO();
vo.executeEmptyRowSet();
/* Use the following snippet in the Application Module (AM) */
OAViewObjectImpl vo = this.getMyDummyVO();
while(vo.hasNext()){
vo.next().remove();
}