Email: [Link]@gmail.
com Phone:+91 7207149158 (Telegram/Google Allo)
Contents
Events Handling 2
1. Button (SubmitButton) 2
2. PopList 2
3. LOV 2
4. HyperLink 2
5. Image 3
Methods for View Object 3
Initialization of the VO 3
1. Method to execute the VO without any bind parameter 3
2. Method to execute the VO by setting bind parameter 3
3. Adding Row Manually 3
4. Iterating the VO Using RowSetIterator 4
Removing the selected row 4
a. Using RowSetIterator 4
b. Using filteredRows Method 5
Different Ways of calling invoketMethod() 5
1. Basic InvokeMethod without params 5
2. Calling Invoke Method with String Param 5
3. Calling Invoke Method with different data types 5
PageContext Methods 6
Invoking AOL Components 6
Page Deployment 7
1. Use the below script to load [Link] / [Link] to MDS 7
2. List of DB Components(Tables,PLSQL-API’s) In-Respect to OAF 7
Basic Data Type Conversion Methods For Frequent Usage 7
1. Conversion of java String to [Link] 8
2. Comparison of dates 8
1|Page
Email: [Link]@[Link] Phone:+91 7207149158 (Telegram/Google Allo)
Refer your friends for : SQL/PLSQL, Oracle Apps Tech and OAF Online Training
Email: [Link]@[Link] Phone:+91 7207149158 (Telegram/Google Allo)
Events Handling
1. Button (SubmitButton)
//In Below Code: “showDetails” refers to the ID of the submitButton Item
if([Link]("showDetails")!=null)
{
[Link]("showStudentData");
}
2. PopList
//In the belowCode “bgPopEvent” refers to the fireAction Property of the link Item
if(eventName!=null && "bgPopEvent".equals(eventName))
{
OAMessageChoiceBean bgPopIDBean =
(OAMessageChoiceBean)[Link]("bgPopID");
String displayStr = [Link](pageContext) ; // Display Attribute
String valueStr = [Link](pageContext); // Value Attribute
throw new OAException("Poplist is fired ---> Bg Name--->" + displayStr + " BG Id -->"+ valueStr,
[Link]) ;
}
3. LOV
//In Below Code : “orgIDLovID” refers to the ID of messageLovInput
String lovSourceID = [Link]();
if(lovSourceID!=null && [Link]("orgIDLovID") )
{
OAMessageLovInputBean orgIDLovIDBean =
(OAMessageLovInputBean)[Link]("orgIDLovID");
String orgIDValue = (String)[Link](pageContext);
OAException exc= new OAException("Selected OrgID-->"+ orgIDValue, [Link]) ;
throw exc;
// throw new OAException("Selected OrgID-->"+ orgIDValue, [Link]) ;
4. HyperLink
//In the belowCode “imageEvent” refers to the fireAction Property of the link Item
String eventName = [Link](EVENT_PARAM) ;
if(eventName!=null && "linkEvent".equals(eventName) )
{
throw new OAException("User Raised an Event On Link-->", [Link]) ;
}
5. Image
2|Page
Email: [Link]@[Link] Phone:+91 7207149158 (Telegram/Google Allo)
Refer your friends for : SQL/PLSQL, Oracle Apps Tech and OAF Online Training
Email: [Link]@[Link] Phone:+91 7207149158 (Telegram/Google Allo)
//In the belowCode “imageEvent” refers to the fireAction Property of the image Item
String eventName = [Link](EVENT_PARAM) ;
else if(eventName!=null && "imageEvent".equals(eventName) )
throw new OAException("User Raised an Event on Image -->", [Link]) ;
Methods for View Object
Initialization of the VO
1. Method to execute the VO without any bind parameter
// Below code has to be written in the [Link] and the VO name differs based on your
project setup
public void initOeOrdersVO()
OeOrderHeadersVOImpl vo = getOeOrderHeadersVO1();
[Link](); //OPEN operation on cursor
2. Method to execute the VO by setting bind parameter
//Method to bind the parameter to the VO
public void initPerPeopleVO()
{
String bgID = “202”;
PerPeopleVOImpl vo = getPerPeopleVO1();
[Link]();
[Link](0,bgID);
[Link]();
3. Adding Row Manually
//Below code refers to add the row in the VO Manually
public void addStudentRowManually()
{
XxcusStudentDataEOVOImpl vo = getXxcusStudentDataEOVO1();
XxcusStudentDataEOVORowImpl row = null;
row = (XxcusStudentDataEOVORowImpl)[Link]();
[Link](row.STATUS_INITIALIZED);
3|Page
Email: [Link]@[Link] Phone:+91 7207149158 (Telegram/Google Allo)
Refer your friends for : SQL/PLSQL, Oracle Apps Tech and OAF Online Training
Email: [Link]@[Link] Phone:+91 7207149158 (Telegram/Google Allo)
Number studentIDNO = getOADBTransaction().getSequenceValue("XXCUS_STUDENT_ID_S") ;
[Link](studentIDNO);
// [Link]();
// [Link]();
[Link]();
[Link]();
[Link](row);
4. Iterating the VO Using RowSetIterator
public void showStudentData()
{
XxcusStudentDataEOVOImpl vo = getXxcusStudentDataEOVO1();
XxcusStudentDataEOVORowImpl row = null ;
RowSetIterator rowIter = [Link]("studentData") ;
while([Link]())
{
row = (XxcusStudentDataEOVORowImpl)[Link](); ///FETCH
[Link]("ID -->" + [Link]());
[Link]("Sname-->"+ [Link]());
[Link]("SelectFlag-->"+ [Link]());
}
[Link]();
}
Removing the selected row
a. Using RowSetIterator
//The below logic should be written in the [Link]
public void deleteStudentRows()
{
XxcusStudentDataEOVOImpl vo = getXxcusStudentDataEOVO1();
XxcusStudentDataEOVORowImpl row = null ;
RowSetIterator rowIter = [Link]("studentData") ;
String empNo = null;
while([Link]())
{
row = (XxcusStudentDataEOVORowImpl)[Link](); ///FETCH
[Link]("ID -->" + [Link]());
[Link]("Sname-->"+ [Link]());
[Link]("SelectFlag-->"+ [Link]());
String selectFlag = [Link]() ;
if(selectFlag!=null && "Y".equals(selectFlag))
{
empNo = empNo + " , " + [Link]() ;
[Link]();/// removes the data from VO
}
}
4|Page
Email: [Link]@[Link] Phone:+91 7207149158 (Telegram/Google Allo)
Refer your friends for : SQL/PLSQL, Oracle Apps Tech and OAF Online Training
Email: [Link]@[Link] Phone:+91 7207149158 (Telegram/Google Allo)
[Link]();
getOADBTransaction().commit();
throw new OAException("Selected Rows Are Deleted Successfully-->"+ empNo , [Link]) ;
b. Using filteredRows Method
//The below logic should be written in the [Link]
public void newDelteStudentRows()
{
XxcusStudentDataEOVOImpl vo = getXxcusStudentDataEOVO1();
XxcusStudentDataEOVORowImpl row = null ;
Row[] rows = [Link]("selectFlag","Y") ;
String empNo = "";
for(int i=0; i<[Link];i++)
{
row = (XxcusStudentDataEOVORowImpl)rows[i];
empNo = empNo + " , " + [Link]() ;
[Link]();
}
if([Link]>=1)
{
getOADBTransaction().commit();
throw new OAException("Selected Rows Are Deleted Successfully-->"+ empNo , [Link]) ;
}
else
{
throw new OAException("Please Select The Rows TO Be Deleted", [Link]) ;
}
}
Different Ways of calling invoketMethod()
1. Basic InvokeMethod without params
OAApplicationModule am = [Link](webBean);
[Link]("initEmployeeDetailsVO");
2. Calling Invoke Method with String Param
Serializable params[]={strUserID};
[Link]("initFormMasterVO", params);
3. Calling Invoke Method with different data types
if([Link]("go")!=null)
{
String fromDateStr = [Link]("fromDate") ;
Date fromDate = stringToDate(fromDateStr);
String toDateStr = [Link]("toDate") ;
5|Page
Email: [Link]@[Link] Phone:+91 7207149158 (Telegram/Google Allo)
Refer your friends for : SQL/PLSQL, Oracle Apps Tech and OAF Online Training
Email: [Link]@[Link] Phone:+91 7207149158 (Telegram/Google Allo)
Date toDate = stringToDate(toDateStr);
OAMessageChoiceBean expenseTypeBean = (OAMessageChoiceBean)[Link]("expenseType");
String expenseTypeStr = (String)[Link](pageContext);
OAMessageTextInputBean expenseClaimIDBean = (OAMessageTextInputBean)[Link]("expenseClaimID");
String expenseClaimIDStr = (String)[Link](pageContext);
Class paramTypes[]={[Link], [Link], [Link], [Link]} ;
Serializable params[]= {fromDate,toDate, expenseTypeStr,expenseClaimIDStr } ;
[Link]("initExpenseDetailsVO",params, paramTypes);
PageContext Methods
Parameters passing from one page to another
Invoking PLSQL Procedure/Function/DML Statement
Invoking Concurrent Program
Invoking Workflow
PPR/SPEL Syntax
Invoking AOL Components
1. Message
a. Single Exception
throw new OAException("FND","XXCUS_CPL_SUCC_MSG",null,[Link],null) ;
b. Bundled Exception
if ([Link]("bundledExc")!=null)
{
ArrayList excArrayList = new ArrayList();
OAException exp1 = new OAException("FND","XXCUS_CPL_FIRST_MSG", null, [Link],null);
OAException exp2 = new OAException("FND","XXCUS_CPL_SCND_MSG", null, [Link],null);
[Link](exp1) ;
[Link](exp2) ;
[Link](excArrayList);
}
2. Lookup
3. Valueset
4. DFF
5. KFF
6|Page
Email: [Link]@[Link] Phone:+91 7207149158 (Telegram/Google Allo)
Refer your friends for : SQL/PLSQL, Oracle Apps Tech and OAF Online Training
Email: [Link]@[Link] Phone:+91 7207149158 (Telegram/Google Allo)
Page Deployment
1. Use the below script to load [Link] / [Link] to MDS
C:\jdev\jdevbin\oaext\bin
import
C:\sridhar\jdev\jdevhome\jdev\myprojects\myprojects\moto\oracle\apps\fnd\webui\ComponentListP
[Link] -username apps -password apps -dbconnection
"(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=[Link])(PORT=1521))(CONNECT_DATA=(SID=VI
S)))" -rootDir C:\sridhar\jdev\jdevhome\jdev\myprojects
2. List of DB Components(Tables,PLSQL-API’s) In-Respect to OAF
Table Name Description
JDR_PATHS Stores document paths, packages and there parent child
relationship.
Primary Key: PATH_DOCID
JDR_COMPONENTS Stores components on documents and OA Framework pages.
Primary Key: COMP_DOCID, COMP_SEQ
JDR_ATTRIBUTES Stores attribute/properties of components on documents and
OA Framework pages.
Primary Key: ATT_COMP_DOCID, ATT_COMP_SEQ, ATT_SEQ
JDR_ATTRIBUTES_TRANS Stores translated attribute values of document components or
OA framework pages.
Primary Key: ATL_COMP_DOCID, ATL_LANG, ATL_COMP_REF,
ATL_NAME
Basic Data Type Conversion Methods For Frequent Usage
Source Data Type Target Data Conversion Sample
Type
[Link] int Number Id = [Link]();
int idIntValue = [Link]();
[Link] String Date dobDomainDate = [Link]();
String dobStr = [Link]();
7|Page
Email: [Link]@[Link] Phone:+91 7207149158 (Telegram/Google Allo)
Refer your friends for : SQL/PLSQL, Oracle Apps Tech and OAF Online Training
Email: [Link]@[Link] Phone:+91 7207149158 (Telegram/Google Allo)
1. Conversion of java String to [Link]
private [Link] stringToDate(String dateS)
{
///String into [Link]
// [Link] into [Link]
[Link] sqlStartDate = null;
if (dateS != null && !"".equals(dateS)) {
String dateFormat = "yyyy-MM-dd";
SimpleDateFormat df = new SimpleDateFormat(dateFormat);
[Link] parsedDate1 = null;
{
try {
parsedDate1 = [Link](dateS); // String into DB
} catch (ParseException e) {
[Link]("exception occurred in conversion ");
throw new OAException("Formatting Issue, Unable to Parse Data") ;
// TODO
}
sqlStartDate = new [Link]([Link]());
}
}
return sqlStartDate;
}
2. Comparison of dates
//Below code will compare To Date with From Date and will throw an error if it is less than from date
// compareTo method return values are : -1 , 0 , 1 for : lessthan, equalto, greater than
if([Link]("go")!=null)
{
String fromDateStr = [Link]("fromDate") ;
Date fromDate = stringToDate(fromDateStr);
String toDateStr = [Link]("toDate") ;
Date toDate = stringToDate(toDateStr);
[Link](this , " From Date -->" + fromDate + " To Date-->"+ toDate , 1);
if(toDate!=null && fromDate!=null )
8|Page
Email: [Link]@[Link] Phone:+91 7207149158 (Telegram/Google Allo)
Refer your friends for : SQL/PLSQL, Oracle Apps Tech and OAF Online Training
Email: [Link]@[Link] Phone:+91 7207149158 (Telegram/Google Allo)
{
if([Link](fromDate) <0 )
{
throw new
OAException("XXCUS","XXDHG_SSHR_EXP_DATE_ERR",null,[Link],null);
**this document is still under preparation, gets updated frequently.
9|Page
Email: [Link]@[Link] Phone:+91 7207149158 (Telegram/Google Allo)
Refer your friends for : SQL/PLSQL, Oracle Apps Tech and OAF Online Training