Win32 API 日本語リファレンス
ホームSystem.WindowsProgramming › WinWatchClose

WinWatchClose

関数
ウィンドウ監視ハンドルを閉じる。
DLLDCIMAN32.dll呼出規約winapi

シグネチャ

// DCIMAN32.dll
#include <windows.h>

void WinWatchClose(
    HWINWATCH hWW
);

パラメーター

名前方向
hWWHWINWATCHin

戻り値の型: void

各言語での呼び出し定義

// DCIMAN32.dll
#include <windows.h>

void WinWatchClose(
    HWINWATCH hWW
);
[DllImport("DCIMAN32.dll", ExactSpelling = true)]
static extern void WinWatchClose(
    IntPtr hWW   // HWINWATCH
);
<DllImport("DCIMAN32.dll", ExactSpelling:=True)>
Public Shared Sub WinWatchClose(
    hWW As IntPtr   ' HWINWATCH
)
End Sub
' hWW : HWINWATCH
Declare PtrSafe Sub WinWatchClose Lib "dciman32" ( _
    ByVal hWW As LongPtr)
' VBA7前提(PtrSafe)。32bit Office では LongPtr→Long。Integer=16bit / Long=32bit / LongLong=64bit。
import ctypes
from ctypes import wintypes

WinWatchClose = ctypes.windll.dciman32.WinWatchClose
WinWatchClose.restype = None
WinWatchClose.argtypes = [
    wintypes.HANDLE,  # hWW : HWINWATCH
]
require 'fiddle'
require 'fiddle/import'

lib = Fiddle.dlopen('DCIMAN32.dll')
WinWatchClose = Fiddle::Function.new(
  lib['WinWatchClose'],
  [
    Fiddle::TYPE_VOIDP,  # hWW : HWINWATCH
  ],
  Fiddle::TYPE_VOID)
#[link(name = "dciman32")]
extern "system" {
    fn WinWatchClose(
        hWW: *mut core::ffi::c_void  // HWINWATCH
    );
}
// crates: windows-sys provides ready-made bindings for this API.
$sig = @"
[DllImport("DCIMAN32.dll")]
public static extern void WinWatchClose(IntPtr hWW);
"@
$api = Add-Type -MemberDefinition $sig -Name 'DCIMAN32_WinWatchClose' -Namespace Win32 -PassThru
# $api::WinWatchClose(hWW)
#uselib "DCIMAN32.dll"
#func global WinWatchClose "WinWatchClose" sptr
; WinWatchClose hWW
; hWW : HWINWATCH -> "sptr"
#uselib "DCIMAN32.dll"
#func global WinWatchClose "WinWatchClose" sptr
; WinWatchClose hWW
; hWW : HWINWATCH -> "sptr"
; void WinWatchClose(HWINWATCH hWW)
#uselib "DCIMAN32.dll"
#func global WinWatchClose "WinWatchClose" intptr
; WinWatchClose hWW
; hWW : HWINWATCH -> "intptr"
import (
	"golang.org/x/sys/windows"
	"unsafe"
)

var (
	dciman32 = windows.NewLazySystemDLL("DCIMAN32.dll")
	procWinWatchClose = dciman32.NewProc("WinWatchClose")
)

// hWW (HWINWATCH)
r1, _, err := procWinWatchClose.Call(
	uintptr(hWW),
)
_ = err  // syscall.Errno (valid when the call sets last-error)
_ = r1   // void
procedure WinWatchClose(
  hWW: THandle   // HWINWATCH
); stdcall;
  external 'DCIMAN32.dll' name 'WinWatchClose';
result := DllCall("DCIMAN32\WinWatchClose"
    , "Ptr", hWW   ; HWINWATCH
    , "Int")   ; return: void
●WinWatchClose(hWW) = DLL("DCIMAN32.dll", "int WinWatchClose(void*)")
# 呼び出し: WinWatchClose(hWW)
# hWW : HWINWATCH -> "void*"
# なでしこ1は32bit・ANSI(Shift_JIS)。文字列=char*(ANSI)、ポインタ/ハンドル=void*(4byte)。