unit ASPOW; {**************************************************************************} { } { AS POWER DLL LIbrary } { version 2.1 } { October 2005. } { UNIT FOR DELPHI } { Copyright (c) AS Computer Software } } {**************************************************************************} interface uses Windows; function asGetCurrentVideoMode(var _1: LongInt; var _2: LongInt; var _3: LongInt; var _4: LongInt): Bool cdecl stdcall; function asCanChangeVideoMode(m_dwBitsPerPixel: LongInt; m_dwWidth: LongInt; m_dwHeight: LongInt; m_dwFrequency: LongInt): LongInt cdecl stdcall; function asChangeVideoModePermanently(m_dwBitsPerPixel: LongInt; m_dwWidth: LongInt; m_dwHeight: LongInt; m_dwFrequency: LongInt): LongInt cdecl stdcall; function asChangeVideoModeTemporarily(m_dwBitsPerPixel: LongInt; m_dwWidth: LongInt; m_dwHeight: LongInt; m_dwFrequency: LongInt): LongInt cdecl stdcall; function asLockWorkStation: Bool cdecl stdcall; function asLockSetForegroundWindow(_1: Word): Bool cdecl stdcall; function asIsDebuggerPresent: Bool cdecl stdcall; function asPerformShutdown: Bool cdecl stdcall; function asPerformReboot: Bool cdecl stdcall; function asPerformLogoff: Bool cdecl stdcall; function asBlockInput: Bool cdecl stdcall; function asUnblockInput: Bool cdecl stdcall; function asSetPriorityReal(_1: HWND): Bool cdecl stdcall; function asSetPriorityHigh(_1: HWND): Bool cdecl stdcall; function asSetPriorityNormal(_1: HWND): Bool cdecl stdcall; function asSetPriorityIdle(_1: HWND): Bool cdecl stdcall; procedure asMinimizeAll:Bool cdecl stdcall; function asIsSafeMode: Bool cdecl stdcall; function asIsDebugUser: Bool cdecl stdcall; function asLockWUpdate(_1: HWND): Bool cdecl stdcall; function asUnlockWUpdate: Bool cdecl stdcall; function asFileToRecycle(_1: PChar): Bool cdecl stdcall; function asEnableScreenS(_1: Bool): Bool cdecl stdcall; function asMonitorOff: Bool cdecl stdcall; function asSystemPowerSuspend: Bool cdecl stdcall; function asSystemPowerHibernate: Bool cdecl stdcall; function asProcSpeed: LongInt cdecl stdcall; function asEmptyRB: Bool cdecl stdcall; function asIsUserAdmin: Bool cdecl stdcall; function asSleepAndWakeUpS(n: Integer): Integer cdecl stdcall; function asSleepAndWakeUp(nDay: Integer; nH: Integer; nM: Integer; nS: Integer): Integer cdecl stdcall; function asOnlySetWakeUpTime(nYear: Integer; nMonth: Integer; nDay: Integer; nH: Integer; nM: Integer; nS: Integer): Integer cdecl stdcall; function asCanHibernate: Bool cdecl stdcall; function asCanSuspend: Bool cdecl stdcall; implementation function asGetCurrentVideoMode; external 'ASPOW.DLL'; function asCanChangeVideoMode; external 'ASPOW.DLL'; function asChangeVideoModePermanently; external 'ASPOW.DLL'; function asChangeVideoModeTemporarily; external 'ASPOW.DLL'; function asLockWorkStation; external 'ASPOW.DLL'; function asLockSetForegroundWindow; external 'ASPOW.DLL'; function asIsDebuggerPresent; external 'ASPOW.DLL'; function asPerformShutdown; external 'ASPOW.DLL'; function asPerformReboot; external 'ASPOW.DLL'; function asPerformLogoff; external 'ASPOW.DLL'; function asBlockInput; external 'ASPOW.DLL'; function asUnblockInput; external 'ASPOW.DLL'; function asSetPriorityReal; external 'ASPOW.DLL'; function asSetPriorityHigh; external 'ASPOW.DLL'; function asSetPriorityNormal; external 'ASPOW.DLL'; function asSetPriorityIdle; external 'ASPOW.DLL'; function asMinimizeAll; external 'ASPOW.DLL'; function asIsSafeMode; external 'ASPOW.DLL'; function asIsDebugUser; external 'ASPOW.DLL'; function asLockWUpdate; external 'ASPOW.DLL'; function asUnlockWUpdate; external 'ASPOW.DLL'; function asFileToRecycle; external 'ASPOW.DLL'; function asEnableScreenS; external 'ASPOW.DLL'; function asMonitorOff; external 'ASPOW.DLL'; function asSystemPowerSuspend; external 'ASPOW.DLL'; function asSystemPowerHibernate; external 'ASPOW.DLL'; function asProcSpeed; external 'ASPOW.DLL'; function asEmptyRB; external 'ASPOW.DLL'; function asIsUserAdmin; external 'ASPOW.DLL'; function asCanHibernate; external 'ASPOW.DLL'; function asCanSuspend; external 'ASPOW.DLL'; function asOnlySetWakeUpTime; external 'ASPOW.DLL'; { if you use Delphi 7, please when you call next functions } { add sleep(100) after it and you will get no error message } { when we wake up PC } function asSleepAndWakeUp; external 'ASPOW.DLL'; function asSleepAndWakeUpS; external 'ASPOW.DLL'; end.