Hello,
I am having a problem with a nsdialogs combo box list which seems to behave differently when i type something in to when i click and select an option from the list.
I add A, B , and C to the list and have ${NSD_OnChange} bring up a message when it is changed. If i type C in to the box the ${NSD_OnChange} messagebox says "C", whereas if i select "C" in the drop down box it still says "A".
I cant figure out what im doing wrong however.
Here is some example code..
I am having a problem with a nsdialogs combo box list which seems to behave differently when i type something in to when i click and select an option from the list.
I add A, B , and C to the list and have ${NSD_OnChange} bring up a message when it is changed. If i type C in to the box the ${NSD_OnChange} messagebox says "C", whereas if i select "C" in the drop down box it still says "A".
I cant figure out what im doing wrong however.
Here is some example code..
Thanks for any help!code:
Name test
OutFile test.exe
!include nsDialogs.nsh
XPStyle on
Page custom nsDialogsPage
Page instfiles
var /global Dialog
var /global COMBOBOX
Function nsDialogsPage
nsDialogs::Create 1018
Pop $Dialog
${If} $Dialog == error
Abort
${EndIf}
${NSD_CreateComboBox} 0 30 80% 12u "test"
pop $COMBOBOX
${NSD_CB_AddString} $COMBOBOX A
${NSD_CB_AddString} $COMBOBOX B
${NSD_CB_AddString} $COMBOBOX C
${NSD_CB_SelectString} $COMBOBOX A
${NSD_OnChange} $COMBOBOX SourceChanged
nsDialogs::Show
FunctionEnd
Function SourceChanged
${NSD_GetText} $COMBOBOX $0
messagebox mb_ok "selection is $0"
FunctionEnd
Section ""
SectionEnd
Comment