How to get value of Text Box in OA Framework?

Well getting the value of a text box from an OA Framework page can be termed as one of the most basic requirements, but still its worth to be learnt.

Before we begin I assume that you have an OAF page (xxTrialPG) and a controller (xxTrialCO). Also I assume that you have created a Text Box bean and have a OAMessageTextInputBean(xxTrialMessageTextInputBean) bean on xxTrialPG.

Let’s take this in steps for easy understanding.

Step 1: Import the OAMessageTextInputBean bean in your controller

import oracle.apps.fnd.framework.webui.beans.message.OAMessageTextInputBean;

Step 2: Create a handle or reference of the xxTrialMessageTextInputBean bean in our controller so that we can control the properties of xxTrialMessageTextInputBean via our controller.

OAMessageTextInputBean xxTrialMessageTextInputBeanHandle = (OAMessageTextInputBean) webBean.findChildRecursive(“xxTrialMessageTextInputBean”);

Step 3: Now using the xxTrialMessageTextInputBeanHandle handle created in step 2 we can get the value of the xxTrialMessageTextInputBean

String xxTrialString = xxTrialMessageTextInputBeanHandle.getValue(pageContext).toString();

Until next post

Keep Learning 🙂


Tagged , , , . Bookmark the permalink.