We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

Generate image of first page.

Thread ID:

Created:

Updated:

Platform:

Replies:

119907 Aug 12,2015 11:02 AM Aug 17,2015 04:50 AM WinRT 6
loading
Tags: SfRichTextBoxAdv
Ric Silva
Asked On August 12, 2015 11:02 AM

On my winRT i have some tiles that represent files.
If the file is a image the tile background uses that image.

I would like to know if there is a way to extract a image that is the first page of the pdf file so i can use it as a preview on the tile.

something like this.



Balasubramanian Sundararajan [Syncfusion]
Replied On August 13, 2015 12:46 PM

Hi Ric,

 

Thank you for using syncfusion product.

 

Yes we can export the images using SfPdfViewer Control. We have created the sample which exports first page of the PDF document as the image by using the following code snippet:


pdfViewerControl1.LoadDocument(ldoc);                    

Image page = pdfViewerControl1.GetPage(0);

Also please find the sample from the below link,

http://www.syncfusion.com/downloads/support/forum/119907/ze/PDFViewerWintRT_2013-1492323365

In this sample, the first five pages of the document will export as images if we clicked the Exported first page.

 

Please let us know if you need further assistance.

 

Thanks,

Balasubramanian


Ric Silva
Replied On August 13, 2015 01:32 PM

so if i have 15 pdf files , in order to create the 15 tiles with the first page images, i have to load the 15 pdf files to the PdfViewer?

Ric Silva
Replied On August 13, 2015 05:17 PM

ok i managed to adapt to my project :)

is there any change that works with doc files too using SfRichTextBoxAdv ?

Narendran Srinivasan [Syncfusion]
Replied On August 14, 2015 07:22 AM

Hi Ric,

Thank you for your update,

Regarding “SfRichTextBoxAdv”
Using SfRichTextBoxAdv control you can retrieve the pages as bitmap image. For Your reference we have prepared a sample to illustrate your requirement to get first page in SfRichTextBoxAdv control as bitmap image. Please do find the sample from below link.

Sample link:
Sample

Regarding “PdfViewer”

Yes, In PdfViewer Control we can load only one document at a time. So if one wants to get the first page of the 15 documents they need to load all those documents separately in PdfViewer Control.


Please let us know if you have any other questions.

Regards,
Narendran



Ric Silva
Replied On August 14, 2015 10:01 AM

im getting 
Error 1 'Syncfusion.UI.Xaml.RichTextBoxAdv.SfRichTextBoxAdv' does not contain a definition for 'GetPageAsImageAsync' and no extension method 'GetPageAsImageAsync' accepting a first argument of type 'Syncfusion.UI.Xaml.RichTextBoxAdv.SfRichTextBoxAdv' could be found (are you missing a using directive or an assembly reference?)

using syncfusion winrt 13.1.0.21


Narendran Srinivasan [Syncfusion]
Replied On August 17, 2015 04:50 AM

Hi Ric,

Thank you for your update,

The support for retrieving page in SfRichTextBoxAdv control as bitmap image is not available with Essential Studio version 13.1.0.21. We have added this support and included in our Essential Studio version 13.2.0.29 service pack 1 and is available for download under the following link.


http://www.syncfusion.com/forums/119866/essential-studio-2015-volume-2-service-pack-release-v13-2-0-34-available-for-download

Please let us know if you have any other questions.

Regards,
Narendran


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;