函数参考


_GUICtrlIpAddress_ShowHide

显示/隐藏 IP 地址控件

#Include <GuiIPAddress.au3>
_GUICtrlIpAddress_ShowHide($hWnd, $iState)

参数

$hWnd 控件句柄
$iState IP 地址控件状态,可以是以下值:(译注:原文无解释,依据示例脚本添加)
@SW_HIDE
@SW_SHOW

返回值

返回 True:控件先前可见
返回 False:控件先前隐藏

注意/说明

None.

相关

示例/演示


#include <GUIConstantsEx.au3>
#include <GuiIPAddress.au3>

$Debug_IP = False ; Check ClassName being passed to IPAddress functions, set to True and use a handle to another control to see it work

_Main()

Func _Main()
    Local $hgui, $hIPAddress

    $hgui = GUICreate("IP Address Control Show/Hide Example", 300, 150)
    $hIPAddress = _GUICtrlIpAddress_Create($hgui, 10, 10)
    GUISetState(@SW_SHOW)

    _GUICtrlIpAddress_Set($hIPAddress, "24.168.2.128")

    Sleep(1000)
    _GUICtrlIpAddress_ShowHide($hIPAddress, @SW_HIDE)
    Sleep(1000)
    _GUICtrlIpAddress_ShowHide($hIPAddress, @SW_SHOW)

    ; Wait for user to close GUI
    Do
    Until GUIGetMsg() = $GUI_EVENT_CLOSE
EndFunc   ;==>_Main