WaitForRangeSourcePrefetch

Document management, Progressive loading, Synchronisation

Description

Waits until a selected-document prefetch job completes, is cancelled, fails or reaches a configured limit

Syntax

Delphi

Function TPDFlib.WaitForRangeSourcePrefetch(JobHandle: Integer;
  TimeoutMS: Cardinal= INFINITE): Integer;

Parameters

JobHandleHandle returned by StartRangeSourcePrefetch for a job on the selected range-backed document
TimeoutMSMaximum time to wait in milliseconds; the default INFINITE waits until a terminal state is reached

Return values

Returns a PDF_RANGE_PREFETCH_STATE_* terminal state, or zero when the timeout expiresAn invalid handle also returns zero and sets

LastErrorCode to 401