TextGRAB SDK Documentation | ITextGRABSDK::SetCaptureTimeout

Setups the timeout of the capture process.

HRESULT SetCaptureTimeout(

LONG timeout,
LONG* oldTimeout


[Visual Basic]

ByVal timeout As Long,
ByRef oldTimeout As Long


void ITextGRABSDK.SetCaptureTimeout(

int timeout,
ref int oldTimeout



[in] new timeout value in milliseconds. Should be in range 0-1000
[out] variable which will hold old timeout value. This parameter can be null in case if you don’t need to store old timeout.


By default capturing time is limited. Which means that if capturing from slow applications – SDK won’t return all text. You can use this method to set your own capture timeout.

Return Value(s)


Return Value(s) Definitions
S_OK (0x00000000) Operation was completed successfully.
E_FAIL (0x80004005) Error.
E_INVALIDARG (0x80070057) Timeout value is our of range.

See Also

ITextGRABSDK interface