Function CountItemListBox(ByVal gadget As long) As Integer
Позволяет получать кол-во пунктов в ListBoxGadget
gadget - номер гаджета
Windows , Linux
#Include "window9.bi"
OpenWindow("",10,10,400,150)
ListBoxGadget(1,10,10,100,80)
AddListBoxItem(1,"Привет0",-1)
AddListBoxItem(1,"Привет1",-1)
AddListBoxItem(1,"Привет2----",-1)
TextGadget(2,150,10,220,20,"Щелкнуть здесь")
Do
var event=WaitEvent()
If event=eventclose Then End
If event=eventgadget Then
If eventnumber()=2 Then
SetGadgetText(2,Str(CountItemListBox(1)) & " пункта в гаджете")
EndIf
EndIf
Loop
Created with the Personal Edition of HelpNDoc: Write EPub books for the iPad