netmare
20th August 2010 08:57 UTC
Assign value to ComboBox
Hi,
I'm displaying SQLServers from neighborhood in ComboBox. After clicking "next" and then "back" on next dialog, previously selected server is being highlighted by instruction:
${NSD_CB_SelectString} $CDServVal $Server
However it fails when value of ComboBox was typed in and doesn't exist in items list (e.g. internet address ). Is there way to fix it without adding typed address to items list?
MSG
20th August 2010 10:19 UTC
In the leave function, store the typed entry in a variable. In the show function, set the control to contain the text you stored.
netmare
20th August 2010 10:58 UTC
Thanks for reply
I'm new in NSIS and only one what i've found about setting value is:
${NSD_CreateComboBox} 50u 17u 250u 12u $Server
It worked perfectly for me until changing Text into ComboBox
Now although $Server contains a value ComboBox appears empty.
Is any other way setting a value for ComboBox ?
Afrow UK
20th August 2010 11:02 UTC
Try NSD_SetText instead.
Stu
netmare
20th August 2010 11:14 UTC
It works. Thanks