How to programmatically set the combobox selected value

This forum contains topics that were moved from Get Satisfaction
B510
Posts: 0
Joined: Wed Jun 04, 2014 2:17 pm

How to programmatically set the combobox selected value

Post by B510 »

Dear All,

I have a combobox that contain the items below:

Red
Blue
Black
Yellow

How to programmatically set the combobox selected value to Blue?

please help

thanks a lot in advance

Regards

B510
Posts: 0
Joined: Wed Jun 04, 2014 2:17 pm

How to programmatically set the combobox selected value

Post by B510 »

I tried codes below, but no luck

Appery('cboColor').val('Blue').selectmenu('refresh');

Kateryna Grynko
Posts: 0
Joined: Thu Nov 15, 2012 9:13 am

How to programmatically set the combobox selected value

Post by Kateryna Grynko »

Hello,

Could you please clarify what you mean under combobox? If this is a checkbow group you can use this code:preAppery('mobilecheckbox_92').find('input').prop('checked', true).checkboxradio('refresh')/preWhere mobilecheckbox_92 is a name of the checkbox with value = Blue.

B510
Posts: 0
Joined: Wed Jun 04, 2014 2:17 pm

How to programmatically set the combobox selected value

Post by B510 »

No.. I meant the select list component... I have 4 items in the select list they are

Red
Blue
Black
Yellow

How to programatically select ' Blue ' as selected ..

Thanks

Evgene Karachevtsev
Posts: 12
Joined: Mon Apr 28, 2014 1:12 pm

How to programmatically set the combobox selected value

Post by Evgene Karachevtsev »

Hello,

In this case your code is correct, please check the value of selected option and name of the select itself, if this won't help, please give us the public the link and clarify on what page your select is

Post Reply