Unreadable code in the telerik ReportViewer

12 posts, 0 answers
  1. jeremy
    jeremy avatar
    23 posts
    Member since:
    May 2011

    Posted 06 Jun 2011 Link to this post

    HI,
       I use "save as" button to extract the report with PDF format, the report is Japanese , but it is unreadable. How I can solve it? Thanks a lot.
    Kind Regards!
    Jeremy.
  2. IvanDT
    Admin
    IvanDT avatar
    76 posts

    Posted 07 Jun 2011 Link to this post

    Hi Jeremy,

    Probably the font that you are using in your report does not support Japanese language. For more information we suggest you review the following article - PDF Rendering.

    Greetings,
    IvanDT
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  3. DevCraft banner
  4. Joel
    Joel avatar
    166 posts
    Member since:
    Oct 2006

    Posted 11 Jul 2011 Link to this post

    I am having the same problem with Japanese characters.  In the PDF only they appear as squares.  I only have 1 Japanese name in an english report.  Displays fine in viewer, and when exported to Excel, looks fine there.  I would think if I had no Japanese fonts installed, I would not be able to see the characters in Excel?
  5. Steve
    Admin
    Steve avatar
    10941 posts

    Posted 12 Jul 2011 Link to this post

    Hello Joel,

    Fonts are embedded in PDF and if the font is not present on the machine where the PDF file is generated, it would not matter even if you have the font on the machine viewing the PDF file. Excel does not embed fonts.

    Greetings,
    Steve
    the Telerik team

    Register for the Q2 2011 What's New Webinar Week. Mark your calendar for the week starting July 18th and book your seat for a walk through of all the exciting stuff we will ship with the new release!

  6. Joel
    Joel avatar
    166 posts
    Member since:
    Oct 2006

    Posted 12 Jul 2011 Link to this post

    Thank you Steve. 

    Once piece of information I should have included is that this is all running on solely on my local machine (Server 2008 web).  String in question is --> 木村信也  .  I would have thought that if I was missing the font completely, I would have problems with viewing the string in IE, Firefox, Excel, Word, VS 2008 or SQL Mangement Studio on the same PC?  Any suggestions to find out what font is actually being used in the other 6 that is not being recognized by the PDF if it is a missing font issue?  Unfortunately I do not have much control over what the users type in, and according to the customer, that Japanese string is important for some reason.
  7. Steve
    Admin
    Steve avatar
    10941 posts

    Posted 15 Jul 2011 Link to this post

    Hello Joel,

    The browsers have a fallback mechanism when a font is missing and they use a substitute instead. I cannot know why it is displayed in VS or Management Studio without more information. Please share what is the font in question and generally it would be best if you provide us with an exported PDF (with the problem) and the problematic report. We would review it and advise you accordingly.

    Greetings,
    Steve
    the Telerik team

    Register for the Q2 2011 What's New Webinar Week. Mark your calendar for the week starting July 18th and book your seat for a walk through of all the exciting stuff we will ship with the new release!

  8. William
    William avatar
    9 posts
    Member since:
    Oct 2010

    Posted 14 May 2012 Link to this post

    Hi,
    I have the same problem.  However,  I'm able to export the report to pdf locally fine (Windows 7).  If I try to export it on our production server (Windows 2008 Server R2) it doesn't work.  i just see little boxes where I should see Japanese characters.  I've played around with the FontEmbedding parameter but that didn't seem to have any impact either locally or in production.  Any ideas?

    -Will
  9. Steve
    Admin
    Steve avatar
    10941 posts

    Posted 15 May 2012 Link to this post

    Hi Will,

    As noted in the Design Considerations for PDF Rendering help article, characters are replaced with boxes whenever the font is missing on your server. You should install that font onto your server and reboot it in order to be taken into account.

    Greetings,
    Steve
    the Telerik team

    BLOGGERS WANTED! Write a review about Telerik Reporting or the new Report Designer, post it on your blog and get a complimentary license for Telerik Reporting. We’ll even promote your blog and help bring you a few fresh readers. Yes, it’s that simple. And it’s free. Get started today >

  10. William
    William avatar
    9 posts
    Member since:
    Oct 2010

    Posted 16 May 2012 Link to this post

    yes, we've installed the Adobe fonts a couple of times an rebooted each time.  Still the export to PDF shows squares.  The odd thing is that I compared the fonts that are on the Windows 2008 RC2 server with the fonts that are on my Windows 7 development machine and the are the same.  However the Windows 2008 RC2 server doesn't export to PDF from ReportViewer correctly.  Is there any further troubleshooting you would suggest?
  11. Steve
    Admin
    Steve avatar
    10941 posts

    Posted 21 May 2012 Link to this post

    Hello William,

    There is no apparent reason why this would not work. Can you verify that the exported PDF from your Windows 7 machine has indeed used the Japanese font you have specified? You can check that in File -> Properties -> Fonts. By default fonts are embedded so you should see (Embedded Subset) right next to the fonts used in the PDF. If the Japanese fonts are not present in the PDF, this means that a fallback font is used. Have you verified that your fonts support Japanese scripts? Use a program like Font Xplorer to check that.

    Greetings,
    Steve
    the Telerik team

    BLOGGERS WANTED! Write a review about Telerik Reporting or the new Report Designer, post it on your blog and get a complimentary license for Telerik Reporting. We’ll even promote your blog and help bring you a few fresh readers. Yes, it’s that simple. And it’s free. Get started today >

  12. William
    William avatar
    9 posts
    Member since:
    Oct 2010

    Posted 23 May 2012 Link to this post

    Hi Steve,

    I did as you asked and I noticed that the PDF is using the "fallback" font.  On my Windows 7 machine it's ArialUnicode but on the Windows 2008 server it's MicrosoftSansSerif.  Apparently the Arial can render the Japanese characters correctly.  How do i change the fallback font on the 2008 server to be Arial?  That should solve the problem.  See attached PDFs for comparison.

    -Will
  13. Steve
    Admin
    Steve avatar
    10941 posts

    Posted 23 May 2012 Link to this post

    Hello William,

    Thanks for the clarification. Judging by your reply, your original font does not support Japanese characters, so that was the reason for the problem in a first place. Arial Unicode font does support Japanese and if you have no problem using it, you should change the font used in Telerik Reports to Arial Unicode, install it on your Windows 2008 Server and reboot the server. This way, Arial Unicode would be used when generating the PDF on your server and it would display properly the font.

    Greetings,
    Steve
    the Telerik team

    BLOGGERS WANTED! Write a review about Telerik Reporting or the new Report Designer, post it on your blog and get a complimentary license for Telerik Reporting. We’ll even promote your blog and help bring you a few fresh readers. Yes, it’s that simple. And it’s free. Get started today >

Back to Top
DevCraft banner