BoldSignA modern eSignature application with affordable pricing. Sign up today for unlimited document usage!
I'm developing a LOB app for my company. The app has forms and auto-complete textboxes for people to fill out. Can syncfusion convert an xaml grid to pdf similar to the new api in windows 8.1 where you can render an xaml to bitmap?
If not, how would I go about using syncfusion to convert the generated bitmap into pdf?
Hi Nate,
Thank you for using Syncfusion product.
Yes it is possible to insert the images into the PDF document. At present, we do support JPEG encoded images. Please find the sample available in the link below,
Please let us know if you need any further assistance.
Regards,
George
Can you please give me an example where the image is already generated in the app and not from a file? Remember that my app takes a snapshot of the xaml grid and creates a bitmap out of it. What I'm trying to do now is create a pdf file out of this image.
Hi Nate,
Thank you for your update.
We have created the sample to convert XAML to bitmap and
then to PDF, Please find the sample available in the link below,
http://www.syncfusion.com/downloads/support/directtrac/116000/XamlToPdfWinRT-1905009446.zip
Please let us know if the solution helps.
Regards,
George
One last question. How do I set the page orientation? I know it should be something obvious, but I can't seem to get it. Many thanks.
Hi Nate,
Thank you
for your update.
Please use
the below code snippet to set the page orientation, herewith we have attached
the sample for your reference.
PdfDocument
document = new PdfDocument();
document.PageSettings.Orientation
= PdfPageOrientation.Landscape;
Sample
Link: http://www.syncfusion.com/downloads/support/directtrac/115661/XamlToPdfWinRT1456811131.zip
Please let
us know if you need any further assistance.
Regards,
George
//Create the Bitmpap from xaml page
await renderTargetBitmap.RenderAsync(SyncfusionForm);
var pixelBuffer = await renderTargetBitmap.GetPixelsAsync(); |