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.

Syncfusion barcode into RDLC report

Thread ID:

Created:

Updated:

Platform:

Replies:

124611 Jun 17,2016 03:31 AM Jun 27,2016 05:12 AM UWP 3
loading
Tags: SfBarcode
Krishna Prasad
Asked On June 17, 2016 03:31 AM


Hi
I am using Syncfusion SfBarcode control in my UWP application.And for my reporting purpose ,
i need to convert this bar code as image or byte array to show in my RDLC  report,unfortunately
RDLC doesn't support direct xaml binding.
Is it possible to convert Syncfusion bar code into jpeg format or byte array in UWP  10.
Thanks in advance.


Chinnu Muniyappan [Syncfusion]
Replied On June 20, 2016 08:36 AM

Hi Krishna, 

Thank you for contacting Syncfusion support. 

Currently we don’t have support for exporting Barcode as image in UWP platform. But as a workaround we can achieve this by drawing Barcode in PDF and then exporting as Image. Please find the workaround sample in the below link. 

Sample link: 

Note: 
1.       Here we use PdfViewer to display the PDF and then convert this to PDF.  
2.       To achieve this workaround, we need to use the below list of assemblies. 
Required Assemblies: 
Syncfusion.Pdf.UWP.dll 
Syncfusion.SfPdfViewer.UWP.dll 
Syncfusion.SfInput.UWP.dll 

We have logged a feature request for converting Barcode to Image, we will implement this in any of our upcoming release.  

Regards, 
Chinnu 


Thomas Albert
Replied On June 24, 2016 02:30 AM

Hi Krishna,

I think you can solve your problem with the following code:

RenderTargetBitmap rtb = new RenderTargetBitmap();
await rtb.RenderAsync(YourSfBarCodeControl, 1000, 1000);
var x = await rtb.GetPixelsAsync();
byte[] bytes = x.ToArray();

Any visible UIElement can be rendered as a bitmap and this bitmap can be converted into a byte array.

Hope this helps

Thomas

KarthikeyanC [Syncfusion]
Replied On June 27, 2016 05:12 AM

Hi Thomas, 
Thanks for your update. 

Regards, 
Karthikeyan.C 


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.

;