Contents Index Topic Contents | ||
Previous Topic: ITask::GetApplicationName Next Topic: ITask::GetParameters |
ITask::GetMaxRunTime
HRESULT GetMaxRunTime( DWORD * pdwMaxRunTime );Retrieves the maximum time, in milliseconds, the task can run before terminating.
- Returns one of the following values:
S_OK The operation was successful. E_INVALIDARG The arguments are not valid. E_OUTOFMEMORY Not enough memory is available.
- pdwMaxRunTime
- Address of a value that contains the maximum run time of the current task.
If the maximum run time is reached during the execution of a task, the Scheduling Agent first sends a WM_CLOSE message to the associated application. If the application hasn't exited within three minutes, TerminateProcess is run.
See also ITask::SetMaxRunTime
Top of Page
© 1997 Microsoft Corporation. All rights reserved. Terms of Use.