I’ve got a PDF I’d like to show in a Book Control.
Since this control can’t use PDFs I have to work around it by either using images or converting the PDF to XAML.
What is the most elegant way to do this?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
I would say that for the purpose of reading in a book control, converting the document to images is a better solution, as that would avoid creating massive XAML documents and a huge amount of processing.
There are a number of free and commercial libraries that can convert a PDF document to images page-by-page. Depending on performance requirements you could either create a list of pages on opening the document or get and convert each page as it is required, possibly with some caching of previous pages. The sky’s the limit really.