Rozbalenφ comba na Üipku dol∙

Postup:
Zalo₧te nov² projekt. Na formulß° dejte combo a tlaΦφtko. Do deklaraΦnφ Φßsti formulß°e zapiÜte:

Private Declare Function SendMessageLong Lib "user32" Alias "SendMessageA" (ByVal hwnd As Long, ByVal wMsg As Long, ByVal wParam As Long, ByVal lParam As Long) As Long
Private Const CB_GETEXTENDEDUI = &H156
Private Const CB_SETEXTENDEDUI = &H155
'Prom∞nnß pro p°epφnßnφ stavu comba
Dim Cstate As Boolean

Na udßlost Load formulß°e zapiÜte k≤d pro naΦtenφ testovacφch polo₧ek do comba:

Private Sub Form_Load()

     Dim i As Long
     For i = 1 To 20
         Combo1.AddItem "Testovacφ polo₧ka " & i
     Next i
     Cstate = False

End Sub

Na udßlost click tlaΦφtka:

Private Sub Command1_Click()

     Cstate = Not Cstate
     SendMessageLong Combo1.hwnd, CB_SETEXTENDEDUI, Abs(Cstate), 0

End Sub

Zp∞t

Autor: The Bozena