SaveCurrentViewToFile

Viewer interaction, rendering and printing

Description

Captures exactly the current client viewport, including persistent overlays such as highlights, selections and search-hit bars, and saves it as a bitmap file

The capture does not change the scroll position, page or zoom, and an empty FileName is rejected

Syntax

Delphi

Function TPDFlibViewer.SaveCurrentViewToFile(Const FileName: WideString): Integer;

Parameters

FileNameTarget path of the bitmap file

Return values

0FileName is empty or the save failed
1The viewport bitmap was written

See also

SnapshotToClipboard, OnSnapshot, TPDFlibViewer