set initial value for combobox

444 views
Skip to first unread message

tri6791

unread,
Jan 9, 2012, 8:42:42 PM1/9/12
to yad-common
For the below command, how do I set "2" as the initial value in the
combobox without rearranging the order of the values?

yad --form --field number:CB '1!2!3'

Thanks,

Tri

slo.s...@gmail.com

unread,
Jan 10, 2012, 1:01:26 PM1/10/12
to yad-c...@googlegroups.com
I don't think you can do that, though you could:
yad --form --field number:CB '2!1!2!3'

In that way, the default is 1, but the drop down still keeps the order of your values.

slo.s...@gmail.com

unread,
Jan 10, 2012, 1:02:00 PM1/10/12
to yad-c...@googlegroups.com
Sorry, I meant the default is now '2'.

tri

unread,
Jan 10, 2012, 6:37:10 PM1/10/12
to yad-common
I thought about doing this but was just wonder if there is a more
elegant solution. Thanks.

On Jan 10, 1:02 pm, "slo.sle...@gmail.com" <slo.sle...@gmail.com>
wrote:
> Sorry, I meant the default is now '2'.
>
> On Tue, Jan 10, 2012 at 10:01 AM, slo.sle...@gmail.com <slo.sle...@gmail.com

Brian

unread,
Apr 9, 2016, 7:46:18 AM4/9/16
to yad-common
Hi,
I know this is an old thread but I was looking for something similar.
It seems that if you prefix an option with "^" then that will be the default option.

yad --form --field number:CB '1!^2!3'
Reply all
Reply to author
Forward
0 new messages