Hello,
I want to execute the selected item in turn, for example, I chose, item 1 3 5, When I press the ok button,
will execute the sub-function 1 3 5, the dialog is minimized, not closed
In addition, I want to know how to get the text of the selected item. The current output is all numbers, like this 10101
Thanks in advance
Macro Execute the selected item
I want to execute the selected item in turn, for example, I chose, item 1 3 5, When I press the ok button,
will execute the sub-function 1 3 5, the dialog is minimized, not closed
In addition, I want to know how to get the text of the selected item. The current output is all numbers, like this 10101
Thanks in advance
Macro Execute the selected item
str L=
;;sub.m1
;;sub.m2
;;sub.m3
;;sub.m4
;;sub.m5
str dd=
;BEGIN DIALOG
;0 "" 0x90C80AC8 0x0 0 0 224 136 "Dialog"
;5 ListBox 0x54230109 0x200 64 16 96 86 ""
;1 Button 0x54030001 0x4 116 116 48 14 "OK"
;2 Button 0x54030000 0x4 168 116 48 14 "Cancel"
;END DIALOG
;DIALOG EDITOR: "" 0x2040801 "*" "" "" ""
str controls = "5"
str lb5
lb5=L
if(!ShowDialog(dd &sub.DlgProc &controls)) ret
out
out lb5
#sub DlgProc
function# hDlg message wParam lParam
sel message
,case WM_INITDIALOG
,case WM_DESTROY
,case WM_COMMAND goto messages2
ret
;messages2
sel wParam
,case IDOK
,case IDCANCEL
ret 1
#sub m1
MES m.timeout=5; m.style="OCa"; m.default='C'
mes("this is m1" "" m)
#sub m2
MES m.timeout=5; m.style="OCa"; m.default='C'
mes("this is m2" "" m)
#sub m3
MES m.timeout=5; m.style="OCa"; m.default='C'
mes("this is m3" "" m)
#sub m4
MES m.timeout=5; m.style="OCa"; m.default='C'
mes("this is m4" "" m)
#sub m5
MES m.timeout=5; m.style="OCa"; m.default='C'
mes("this is m5" "" m)