Function Reference

_GUICtrlComboBox_Destroy

コントロールを削除します。

#Include <GuiComboBox.au3>
_GUICtrlComboBox_Destroy(ByRef $hWnd)

 

パラメータ

$hWnd コントロールのハンドル

 

返し値

成功: True、ハンドルが0に設定されます
失敗: False

 

注意

_GUICtrlComboBox_Createで作成されたリストボックスのみに使用できます。

 

関連

_GUICtrlComboBox_Create

 


#AutoIt3Wrapper_au3check_parameters=-d -w 1 -w 2 -w 3 -w 4 -w 5 -w 6
#include <GUIComboBox.au3>
#include <GuiConstantsEx.au3>
#include <Constants.au3>

Opt('MustDeclareVars', 1)

$Debug_CB = False ; ComboBox/ComboBoxEx関数に渡されるClassNameを調べる。動作を確認するにはTrueを設定し、他のコントロールのハンドルを使用

_Main()

Func _Main()
    Local $hGUI, $hCombo

    ; GUIを作成
    $hGUI = GUICreate("(UDF Created) ComboBox Destroy", 400, 296)
    $hCombo = _GUICtrlComboBox_Create($hGUI, "", 2, 2, 396, 296)
    GUISetState()

    ; ファイルを追加
    _GUICtrlComboBox_BeginUpdate($hCombo)
    _GUICtrlComboBox_AddDir($hCombo, "", $DDL_DRIVES, False)
    _GUICtrlComboBox_EndUpdate($hCombo)

    ; コンボボックスを破棄
    MsgBox(4160, "Information", "Destroy ComboBox")
    MsgBox(4160, "Information", "Destroyed: " & _GUICtrlComboBox_Destroy($hCombo))
   
    ; ユーザーが終了するまでループ
    Do
    Until GUIGetMsg() = $GUI_EVENT_CLOSE
    GUIDelete()
EndFunc   ;==>_Main