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

Access to Combo Box values into Table

0 Kudos
293

Hello,

We Can't set value into a drop downlist (comboBox) into a tabcontrol :

The variable oCombo into

var oCombo = session.findById("wnd[0]/usr/tabsTAB_GROUP_10/tabp10\\TAB02/ssubSUB_GROUP_10:SAPLIQS0:7235/subCUSTOM_SCREEN:SAPLIQS0:7212/subSUBSCREEN_2:SAPLIQS0:7336/tblSAPLIQS0MASSNAH_VIEWER3/cmbVIQMSM-PARVW[8,0]");

Is Undefined

whereas

We access good to a simple comboBox (not into a tabcontrol) in the same screen

as

var oCombo2 = session.findById("wnd[0]/usr/tabsTAB_GROUP_10/tabp10\\TAB02/ssubSUB_GROUP_10:SAPLIQS0:7235/subCUSTOM_SCREEN:SAPLIQS0:7212/subSUBSCREEN_1:SAPLIQS0:7520/cmbVIQMEL-PRIOK");

PRODUCT VERSION = PERSONAS 3.0 SP7.

Do you have any idea ?

Thanks by advance,

Best regards.

Donatien.

Accepted Solutions (0)

Answers (1)

Answers (1)

Brian_Wills
Contributor

Hello,

I'm going to give you a partial answer as I cannot get a full solution for you.

This script will allow you to read the value from the table. Unfortunately, Personas does not support modifying the cell value for a combo box yet. They support modifying text fields, radio buttons, buttons, and check boxes. You can see this info under "modifyCell" in the API help for Personas.

This is the script to read from a table:

//Get the table control
var table = session.findById("wnd[0]/usr/subSUB_ALL:SAPLCOIH:*/ssubSUB_LEVEL:SAPLCOIH:*/tabsTS_1100/tabpVGUE/ssubSUB_AUFTRAG:SAPLCOVG:3010/tblSAPLCOVGTCTRL_3010");

//Get the column name based on the index.  Base 0.
var col_name = table.getColumnName(6); //(index)
session.utils.log('column name =>' + col_name);
//Get the cell value. Base 0.
var value = table.getCellValue(0, col_name); //(row, column name)
session.utils.log('column value =>' + value);

I hope this helps. You may want to report an this as an Incident to SAP to see if they can help. Thanks, Brian