NetScheduleJobGetInfo function (lmat.h)
[NetScheduleJobGetInfo is no longer available for use as of Windows 8. Instead, use the Task Scheduler 2.0 Interfaces.
]
The NetScheduleJobGetInfo function retrieves information about a particular job queued on a specified computer. This function requires that the schedule service be started.
Syntax
NET_API_STATUS NET_API_FUNCTION NetScheduleJobGetInfo(
[in, optional] LPCWSTR Servername,
[in] DWORD JobId,
[out] LPBYTE *PointerToBuffer
);
Parameters
[in, optional] Servername
A pointer to a constant string that specifies the DNS or NetBIOS name of the remote server on which the function is to execute. If this parameter is NULL, the local computer is used.
[in] JobId
A value that indicates the identifier of the job for which to retrieve information.
[out] PointerToBuffer
A pointer to the buffer that receives the AT_INFO structure describing the specified job. This buffer is allocated by the system and must be freed using the NetApiBufferFree function. For more information, see Network Management Function Buffers and Network Management Function Buffer Lengths.
Return value
If the function succeeds, the return value is NERR_Success.
If the function fails, the return value is a system error code. For a list of error codes, see System Error Codes.
Remarks
Normally only members of the local Administrators group on the computer where the schedule job is being enumerated can successfully execute this function. If the server name passed in the string pointed to by the Servername parameter is a remote server, then only members of the local Administrators group on the server can successfully execute this function.
If the following registry value has the least significant bit set (for example, 0x00000001), then users belonging to the Server Operators group can also successfully execute this function.
HKLM\System\CurrentControlSet\Control\Lsa\SubmitControl
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows 2000 Professional [desktop apps only] |
Minimum supported server | Windows 2000 Server [desktop apps only] |
Target Platform | Windows |
Header | lmat.h (include Lmat.h) |
Library | Netapi32.lib |
DLL | Netapi32.dll |