Started by aoxiangzcr ·
2007-12-10 12:59 UTC ·
5 replies · SMF topic #109
aoxiangzcr
2007-12-10 12:59 UTC
Today,I drag and drop a ComboBox on my form,it's style is Drop down.When I design my form ,I add comboBox's list in Studio.On runtime,I want to get the list's index and I used the function "(Setq rValue (dcl_ComboBox_GetCurSel Project2_Form1_ComboBox1))",but it return nil .Is there any mistake about it?And what can I do about it ?
Regards,
Aoxiangzcr
bazzacad
2007-12-10 17:48 UTC
TRY:
(Setq rValue (dcl_ComboBox_GetTBText Project1_Form1_ComboBox1))
owenwengerd
2007-12-10 22:03 UTC
A NIL return indicates an error in the argument, such as passing a NIL control name. Make sure the symbol name is correct, and also make sure you call this function while the control still exists (i.e. before the form is closed).
aoxiangzcr
2007-12-11 00:50 UTC
I check it ,but the argument is right,and when I use "SetCurSel " ,it return right value.So ,I do't know what happen.
owenwengerd
2007-12-11 02:59 UTC
If you can attach your .odcl and .lsp files, perhaps someone can figure out what is going on.
aoxiangzcr
2007-12-12 03:10 UTC
I have got it .Thanks