QUERY_SERVICE_LOCK_STATUSW structure (winsvc.h)

Contains information about the lock status of a service control manager database. It is used by the QueryServiceLockStatus function.

Syntax

typedef struct _QUERY_SERVICE_LOCK_STATUSW {
  DWORD  fIsLocked;
  LPWSTR lpLockOwner;
  DWORD  dwLockDuration;
} QUERY_SERVICE_LOCK_STATUSW, *LPQUERY_SERVICE_LOCK_STATUSW;

Members

fIsLocked

The lock status of the database. If this member is nonzero, the database is locked. If it is zero, the database is unlocked.

lpLockOwner

The name of the user who acquired the lock.

dwLockDuration

The time since the lock was first acquired, in seconds.

Remarks

Note

The winsvc.h header defines QUERY_SERVICE_LOCK_STATUS as an alias which automatically selects the ANSI or Unicode version of this function based on the definition of the UNICODE preprocessor constant. Mixing usage of the encoding-neutral alias with code that not encoding-neutral can lead to mismatches that result in compilation or runtime errors. For more information, see Conventions for Function Prototypes.

Requirements

Requirement Value
Minimum supported client Windows XP [desktop apps only]
Minimum supported server Windows Server 2003 [desktop apps only]
Header winsvc.h (include Windows.h)

See also

QueryServiceLockStatus