# Function Reference

# _GUICtrlComboBoxEx_Destroy

Delete the control

#include <GuiComboBoxEx.au3>
_GUICtrlComboBoxEx_Destroy ( ByRef $hWnd )

## Parameters

$hWnd | Handle to the control

## Return Value

Success: | True, $hWnd is set to 0.
Failure: | False.

## Remarks

Restricted to only be used on ComboBoxEx controls created with _GUICtrlComboBoxEx_Create().

## Related

_GUICtrlComboBoxEx_Create

## Example

    #include <GuiComboBoxEx.au3>
    #include <GUIConstantsEx.au3>
    #include <MsgBoxConstants.au3>

    Example()

    Func Example()
        Local $hGUI, $hCombo

        ; Create GUI
        $hGUI = GUICreate("ComboBoxEx Destroy", 400, 300)
        $hCombo = _GUICtrlComboBoxEx_Create($hGUI, "This is a test|Line 2", 2, 2, 394, 268)
        GUISetState(@SW_SHOW)

        _GUICtrlComboBoxEx_AddString($hCombo, "Some More Text")
        _GUICtrlComboBoxEx_InsertString($hCombo, "Inserted Text", 1)

        ;Destroy control
        MsgBox($MB_SYSTEMMODAL, "Information", "Destroy the control")
        _GUICtrlComboBoxEx_Destroy($hCombo)

        ; Loop until the user exits.
        Do
        Until GUIGetMsg() = $GUI_EVENT_CLOSE
    EndFunc   ;==>Example