ホーム › System.Registry › RegDisablePredefinedCache
RegDisablePredefinedCache
関数現在スレッドのHKCU定義済みキーキャッシュを無効化する。
シグネチャ
// ADVAPI32.dll
#include <windows.h>
WIN32_ERROR RegDisablePredefinedCache(void);パラメーターなし。戻り値: WIN32_ERROR
各言語での呼び出し定義
// ADVAPI32.dll
#include <windows.h>
WIN32_ERROR RegDisablePredefinedCache(void);[DllImport("ADVAPI32.dll", ExactSpelling = true)]
static extern uint RegDisablePredefinedCache();<DllImport("ADVAPI32.dll", ExactSpelling:=True)>
Public Shared Function RegDisablePredefinedCache() As UInteger
End FunctionDeclare PtrSafe Function RegDisablePredefinedCache Lib "advapi32" () As Long
' VBA7前提(PtrSafe)。32bit Office では LongPtr→Long。Integer=16bit / Long=32bit / LongLong=64bit。import ctypes
from ctypes import wintypes
RegDisablePredefinedCache = ctypes.windll.advapi32.RegDisablePredefinedCache
RegDisablePredefinedCache.restype = wintypes.DWORD
RegDisablePredefinedCache.argtypes = []require 'fiddle'
require 'fiddle/import'
lib = Fiddle.dlopen('ADVAPI32.dll')
RegDisablePredefinedCache = Fiddle::Function.new(
lib['RegDisablePredefinedCache'],
[],
-Fiddle::TYPE_INT)#[link(name = "advapi32")]
extern "system" {
fn RegDisablePredefinedCache() -> u32;
}
// crates: windows-sys provides ready-made bindings for this API.$sig = @"
[DllImport("ADVAPI32.dll")]
public static extern uint RegDisablePredefinedCache();
"@
$api = Add-Type -MemberDefinition $sig -Name 'ADVAPI32_RegDisablePredefinedCache' -Namespace Win32 -PassThru
# $api::RegDisablePredefinedCache()#uselib "ADVAPI32.dll"
#func global RegDisablePredefinedCache "RegDisablePredefinedCache"
; RegDisablePredefinedCache ; 戻り値は stat
; ※HSP3.7は #func のため戻り値はシステム変数 stat に格納されます。#uselib "ADVAPI32.dll"
#cfunc global RegDisablePredefinedCache "RegDisablePredefinedCache"
; res = RegDisablePredefinedCache(); WIN32_ERROR RegDisablePredefinedCache()
#uselib "ADVAPI32.dll"
#cfunc global RegDisablePredefinedCache "RegDisablePredefinedCache"
; res = RegDisablePredefinedCache()import (
"golang.org/x/sys/windows"
"unsafe"
)
var (
advapi32 = windows.NewLazySystemDLL("ADVAPI32.dll")
procRegDisablePredefinedCache = advapi32.NewProc("RegDisablePredefinedCache")
)
r1, _, err := procRegDisablePredefinedCache.Call()
_ = err // syscall.Errno (valid when the call sets last-error)
_ = r1 // WIN32_ERRORfunction RegDisablePredefinedCache: DWORD; stdcall;
external 'ADVAPI32.dll' name 'RegDisablePredefinedCache';result := DllCall("ADVAPI32\RegDisablePredefinedCache", "UInt")●RegDisablePredefinedCache() = DLL("ADVAPI32.dll", "dword RegDisablePredefinedCache()")
# 呼び出し: RegDisablePredefinedCache()
# なでしこ1は32bit・ANSI(Shift_JIS)。文字列=char*(ANSI)、ポインタ/ハンドル=void*(4byte)。