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. Image for the cookie policy date

Euro sign culture setting in PdfDocument


In my app I use PdfGrid's to show text in a pdf file. In the cells I also must add text with a culture currency like:

            var pdfGridParagraph3 = new Syncfusion.Pdf.Grid.PdfGrid();
            pdfGridParagraph3.Columns[0].Width = 200;
            var pdfGridRowParagraph3Details1 = pdfGridParagraph3.Rows.Add();
            pdfGridRowParagraph3Details1.Cells[0].Value = "€ 200.000";

Unfortunetly the Euro sign is not visible in the created pdf file.

Do you have a solution?

9 Replies

KC Karthikeyan Chandrasekar Syncfusion Team November 12, 2018 12:06 AM

Hi Vince, 
By default PdfGrid uses Standard Font to draw the text in the PDF document. As Euro is a Unicode character we have to use True Type font to get this supported. Please use the below code snippet to get this issue resolved. 
Stream fontStream = typeof(MainPage).GetTypeInfo().Assembly.GetManifestResourceStream("Sample.Assets.Arial.ttf"); 
pdfGridParagraph3.Style.Font = new PdfTrueTypeFont(fontStream, 14); 
Note: The TTF file should be placed in the Xamarin application. 

Revert me back if you need further assistance in this. 

VI Vince November 12, 2018 03:15 AM

Hallo Karthikeyan,

I saw this code snipped before but was not able to implement it.

Do you have a working example for Xamarin Android?

Best regards,


KC Karthikeyan Chandrasekar Syncfusion Team November 12, 2018 05:29 AM

Hi Vince, 
Please find the simple sample below. 

VI Vince November 12, 2018 06:51 AM

Hallo KarthikeyanC,

I see that I was missing the reference "using System.Reflection;" in my app. 

But still it is not working because your code line "Stream fontStream = typeof(MainActivity).GetTypeInfo().Assembly.GetManifestResourceStream("GettingstartedAndroid.Assets.Arial.TTF");" returns the next error:

Unhandled Exception:
System.ArgumentNullException: Value cannot be null.
Parameter name: fontStream

Do you know what is going wrong?

Best regards,

p.s. the file "Arial.TTF" is available in the map Assets of my app.

KC Karthikeyan Chandrasekar Syncfusion Team November 13, 2018 07:44 AM

Hi Vince, 
Thank you for your update. 
We are suspecting the font file (arial.ttf) build action is not set as Embedded Resource. So, the font stream becomes null and the null reference exception throws when try to accessing. 

Kindly check, step 7 from below KB to mark the font file as Embedded Resource. 

Please try our suggestion and let us know If you need further assistance in this. 

VI Vince November 13, 2018 08:21 AM

Hi KarthikeyanC,

I changed the Build Action of the file Arial.ttf to Embedded Resource as you mentioned. Unfortunetly the error (null reference for fontStream) is still there.

Do you have another tip?

KC Karthikeyan Chandrasekar Syncfusion Team November 14, 2018 10:59 AM

Hi Vince, 
Thank you for your update. 
Can you please confirm, is the sample which we have provided on November 12, 2018 10:29 AM UTC in the forum is it working fine in your end?. The stream for the Arial.ttf font file can be retrieved using below code snippet. 
Stream fontStream = typeof(MainActivity).GetTypeInfo().Assembly.GetManifestResourceStream("GettingstartedAndroid.Assets.Arial.ttf"); 
Please find the font file path of GetManifestResourceStream parameter 
GettingstartedAndroid  - Name of the sample 
Assets                            - Folder name 
Arial.ttf                          - Font file name 
Make sure the GetManifestResourceStream parameter set properly. 

VI Vince November 14, 2018 11:34 AM

Hi KarthikeyanC,

Unfortunetly not. 

The GetManifestResourceStream is set with the correct namespace although it is already available in my class.

I also can not run your sample because I get an error (not enough memmory available).

So I still have no Euro sign in my pdf report.

Best regards,


KC Karthikeyan Chandrasekar Syncfusion Team November 15, 2018 04:45 AM

Hi Vince, 
We have created a new incident for further followup in this issue, can we have a web meeting to address this issue. Please follow the incident which is created under your account to get further information. 


Live Chat Icon For mobile
Up arrow icon