ホーム › NetworkManagement.Rras › MprAdminInterfaceUpdatePhonebookInfo
MprAdminInterfaceUpdatePhonebookInfo
関数インターフェイスの電話帳情報を最新の状態に更新する。
シグネチャ
// MPRAPI.dll
#include <windows.h>
DWORD MprAdminInterfaceUpdatePhonebookInfo(
INT_PTR hMprServer,
HANDLE hInterface
);パラメーター
| 名前 | 型 | 方向 |
|---|---|---|
| hMprServer | INT_PTR | in |
| hInterface | HANDLE | in |
戻り値の型: DWORD
各言語での呼び出し定義
// MPRAPI.dll
#include <windows.h>
DWORD MprAdminInterfaceUpdatePhonebookInfo(
INT_PTR hMprServer,
HANDLE hInterface
);[DllImport("MPRAPI.dll", ExactSpelling = true)]
static extern uint MprAdminInterfaceUpdatePhonebookInfo(
IntPtr hMprServer, // INT_PTR
IntPtr hInterface // HANDLE
);<DllImport("MPRAPI.dll", ExactSpelling:=True)>
Public Shared Function MprAdminInterfaceUpdatePhonebookInfo(
hMprServer As IntPtr, ' INT_PTR
hInterface As IntPtr ' HANDLE
) As UInteger
End Function' hMprServer : INT_PTR
' hInterface : HANDLE
Declare PtrSafe Function MprAdminInterfaceUpdatePhonebookInfo Lib "mprapi" ( _
ByVal hMprServer As LongPtr, _
ByVal hInterface As LongPtr) As Long
' VBA7前提(PtrSafe)。32bit Office では LongPtr→Long。Integer=16bit / Long=32bit / LongLong=64bit。import ctypes
from ctypes import wintypes
MprAdminInterfaceUpdatePhonebookInfo = ctypes.windll.mprapi.MprAdminInterfaceUpdatePhonebookInfo
MprAdminInterfaceUpdatePhonebookInfo.restype = wintypes.DWORD
MprAdminInterfaceUpdatePhonebookInfo.argtypes = [
ctypes.c_ssize_t, # hMprServer : INT_PTR
wintypes.HANDLE, # hInterface : HANDLE
]require 'fiddle'
require 'fiddle/import'
lib = Fiddle.dlopen('MPRAPI.dll')
MprAdminInterfaceUpdatePhonebookInfo = Fiddle::Function.new(
lib['MprAdminInterfaceUpdatePhonebookInfo'],
[
Fiddle::TYPE_INTPTR_T, # hMprServer : INT_PTR
Fiddle::TYPE_VOIDP, # hInterface : HANDLE
],
-Fiddle::TYPE_INT)#[link(name = "mprapi")]
extern "system" {
fn MprAdminInterfaceUpdatePhonebookInfo(
hMprServer: isize, // INT_PTR
hInterface: *mut core::ffi::c_void // HANDLE
) -> u32;
}
// crates: windows-sys provides ready-made bindings for this API.$sig = @"
[DllImport("MPRAPI.dll")]
public static extern uint MprAdminInterfaceUpdatePhonebookInfo(IntPtr hMprServer, IntPtr hInterface);
"@
$api = Add-Type -MemberDefinition $sig -Name 'MPRAPI_MprAdminInterfaceUpdatePhonebookInfo' -Namespace Win32 -PassThru
# $api::MprAdminInterfaceUpdatePhonebookInfo(hMprServer, hInterface)#uselib "MPRAPI.dll"
#func global MprAdminInterfaceUpdatePhonebookInfo "MprAdminInterfaceUpdatePhonebookInfo" sptr, sptr
; MprAdminInterfaceUpdatePhonebookInfo hMprServer, hInterface ; 戻り値は stat
; hMprServer : INT_PTR -> "sptr"
; hInterface : HANDLE -> "sptr"
; ※HSP3.7は #func のため戻り値はシステム変数 stat に格納されます。#uselib "MPRAPI.dll"
#cfunc global MprAdminInterfaceUpdatePhonebookInfo "MprAdminInterfaceUpdatePhonebookInfo" sptr, sptr
; res = MprAdminInterfaceUpdatePhonebookInfo(hMprServer, hInterface)
; hMprServer : INT_PTR -> "sptr"
; hInterface : HANDLE -> "sptr"; DWORD MprAdminInterfaceUpdatePhonebookInfo(INT_PTR hMprServer, HANDLE hInterface)
#uselib "MPRAPI.dll"
#cfunc global MprAdminInterfaceUpdatePhonebookInfo "MprAdminInterfaceUpdatePhonebookInfo" intptr, intptr
; res = MprAdminInterfaceUpdatePhonebookInfo(hMprServer, hInterface)
; hMprServer : INT_PTR -> "intptr"
; hInterface : HANDLE -> "intptr"import (
"golang.org/x/sys/windows"
"unsafe"
)
var (
mprapi = windows.NewLazySystemDLL("MPRAPI.dll")
procMprAdminInterfaceUpdatePhonebookInfo = mprapi.NewProc("MprAdminInterfaceUpdatePhonebookInfo")
)
// hMprServer (INT_PTR), hInterface (HANDLE)
r1, _, err := procMprAdminInterfaceUpdatePhonebookInfo.Call(
uintptr(hMprServer),
uintptr(hInterface),
)
_ = err // syscall.Errno (valid when the call sets last-error)
_ = r1 // DWORDfunction MprAdminInterfaceUpdatePhonebookInfo(
hMprServer: NativeInt; // INT_PTR
hInterface: THandle // HANDLE
): DWORD; stdcall;
external 'MPRAPI.dll' name 'MprAdminInterfaceUpdatePhonebookInfo';result := DllCall("MPRAPI\MprAdminInterfaceUpdatePhonebookInfo"
, "Ptr", hMprServer ; INT_PTR
, "Ptr", hInterface ; HANDLE
, "UInt") ; return: DWORD●MprAdminInterfaceUpdatePhonebookInfo(hMprServer, hInterface) = DLL("MPRAPI.dll", "dword MprAdminInterfaceUpdatePhonebookInfo(int, void*)")
# 呼び出し: MprAdminInterfaceUpdatePhonebookInfo(hMprServer, hInterface)
# hMprServer : INT_PTR -> "int"
# hInterface : HANDLE -> "void*"
# なでしこ1は32bit・ANSI(Shift_JIS)。文字列=char*(ANSI)、ポインタ/ハンドル=void*(4byte)。