cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Help us improve the PTC Community by taking this short Community Survey! X

How to get text field values in formProcessor?

AntonBagryanov
12-Amethyst

How to get text field values in formProcessor?

Hi!

Anybody know how to get text field values, that i was inserted in some wizard, in the formProcessor that will handle this wizard?

7 REPLIES 7

nmCommandBean.getText().get(...)

LoriSood
22-Sapphire III
(To:VasiliyRepecki)

Anton, did Vasiliy's suggestion get you what you needed?

No.

This method return null value. I can't find something about getting text fields values from wizards in customization guide. May be you have any manuals?

dharmateja
5-Regular Member
(To:AntonBagryanov)

 this method is returning null value. can u tell me how to get the value given in the text box?

If you know the parameter name, you can use something like this:

String myStringValue = nmcommandbean.getTextParameter("myStringParamKey");

Or you can get the parameter map and pull it from there:

HashMap<String,Object> params = ((ObjectBean)list.get(i)).getParameterMap();

Iterator<String> iterator = params.keySet().iterator();

while (iterator. hasNext()) {

String key = (String) iterator.next();

String[] valueArray = (String[])params.get(key);

if (key.contains("myStringParamKey") && !(key.contains("___old"))) {

String myStringValue = valueArray[0];

}

}

Thanks, Teresa! I'll try it later.

KD
12-Amethyst
12-Amethyst
(To:AntonBagryanov)

If the jsp is custom jsp then its recommend to use wrapper tag from tag lib to create "TextBox" or If using HTML tag for input, the tag name must be following style for being read at NmCommandBean. “null___[attribute name]___textbox” If you want to use combo box, you must set name like following for NmCommandBean. “null___[attribute name]___combobox”

Regards,

Kauhsik

Announcements


Top Tags