AdvApi32LookupPrivilegeValue Method
Retrieves the locally unique identifier (LUID) used on a specified system,
to locally represent the specified privilege name.
Namespace: DevCase.Win32.NativeMethodsAssembly: DevCase.net48 (in DevCase.net48.dll) Version: 6.0.0.0 (6.0)
XMLNS for XAML: Not mapped to an xmlns.
[DllImportAttribute("AdvApi32.dll", CharSet = CharSet.Auto, BestFitMapping = false,
ThrowOnUnmappableChar = true, SetLastError = true)]
public static bool LookupPrivilegeValue(
string systemName,
string name,
ref Luid refLuid
)
<DllImportAttribute("AdvApi32.dll", CharSet := CharSet.Auto, BestFitMapping := false,
ThrowOnUnmappableChar := true, SetLastError := true>]
Public Shared Function LookupPrivilegeValue (
systemName As String,
name As String,
ByRef refLuid As Luid
) As Boolean
Dim systemName As String
Dim name As String
Dim refLuid As Luid
Dim returnValue As Boolean
returnValue = AdvApi32.LookupPrivilegeValue(systemName,
name, refLuid)
public:
[DllImportAttribute(L"AdvApi32.dll", CharSet = CharSet::Auto, BestFitMapping = false,
ThrowOnUnmappableChar = true, SetLastError = true)]
static bool LookupPrivilegeValue(
String^ systemName,
String^ name,
Luid% refLuid
)
[<DllImportAttribute("AdvApi32.dll", CharSet = CharSet.Auto, BestFitMapping = false,
ThrowOnUnmappableChar = true, SetLastError = true)>]
static member LookupPrivilegeValue :
systemName : string *
name : string *
refLuid : Luid byref -> bool
No code example is currently available or this language may not be supported.
- systemName String
-
A pointer to a null-terminated string that specifies the name of the system on which the privilege name is retrieved.
If a null string is specified, the function attempts to find the privilege name on the local system
- name String
-
A pointer to a null-terminated string that specifies the name of the privilege,
as defined in the Winnt.h header file.
For example, this parameter could specify the constant, SE_SECURITY_NAME,
or its corresponding string, "SeSecurityPrivilege".
- refLuid Luid
-
A pointer to a variable that receives the LUID by which the privilege is known on
the system specified by the systemName parameter.
Boolean
If the function succeeds, the function returns
.
If the function fails, it returns
.
To get extended error information, call
GetLastWin32Error.