Before telling you how to execute a VO on page load, I assume that you have your VO created and also have attached the VO to the correct AM (Application Module).
Now, let’s assume that the name of your VO is xxTrialVO and also the name of the AM is xxTrialAM.
Let’s take this stepwise for a better understanding.
Step 1 import the AMImpl into your controller attached to the OA Framework page.
To do this just write the following code.
import oracle.apps…..server.XXTrialAMImpl;
Note: the import path will be different for you and will depend on the folder structure that you have defined.
Step 2 import the VOImpl into your controller attached to the OA Framework page.
import oracle.apps…..server.XXTrialVOImpl;
Note: the import path will be different for you and will depend on the folder structure that you have defined.
Steps 3 before the starting of processRequest method create an instance of the xxTrialAMImpl as shown below.
public xxTrialAMImpl am;
Step 4 in the processRequest method you need to instantiate the application module.
am = (xxTrialAMImpl)pageContext.getApplicationModule(webBean);
Step 5 Now we need to create an instance of the xxTrialVOImpl and then execute it.
XXTrialVOImpl TrialVO = (XXTrialVOImpl)am.getXXTrialVO1();
TrialVO.executeQuery();
Thanks for reading.