GetPageThumbnailDataToString
Page properties and extraction
Description
Returns the stored or filter-decoded /Thumb image payload for one page as a binary AnsiString
Syntax
Function TPDFlib.GetPageThumbnailDataToString(Page, DataMode: Integer): AnsiString;
Parameters
| Page | One-based page number |
|---|---|
| DataMode | PDF_THUMBNAIL_DATA_RAW keeps the stream filters intact, while PDF_THUMBNAIL_DATA_DECODED removes supported PDF wrapping filters |
Return values
Returns the binary thumbnail payload, or an empty string when the page, mode, thumbnail type or stream data is invalid
Remarks
Use GetPageThumbnailDataToStream for large thumbnails to avoid a second in-memory result copy
Terminal image encodings such as DCTDecode and JPXDecode remain native compressed payloads in decoded mode
See also
GetPageThumbnailInfo, DeletePageThumbnail, SetPageThumbnailFromString