Click here to Skip to main content
12,954,601 members (55,056 online)
Click here to Skip to main content
Add your own
alternative version


5 bookmarked
Posted 25 Mar 2014

How to Export Crystal Report in Regional Language Marathi, Hindi, Arabic.

, 25 Mar 2014 CPOL
Rate this:
Please Sign up or sign in to vote.
I am going to resolve Issue of Font Displaying Box or Junk While Exporting Crystal report.


I am going to resolve Issue of Font Displaying Box or Junk While Exporting Crystal report which Is created In Regional Language Like Marathi, Hindi ,Arabic. Most Issue Is because of The font .

This Article will helps Developers who are developing Crystal report in there Regional Language because there are not much Article on localizing Crystal report .

The Font Which We use while developing Report Should be there on Server

Where you are going to Deploy your application .

If font is not there then it will create Junk like Characters .

Tip: You Cannot use any font to develop Report you should use Unicode Font for it.

Main Step is install Font on Server or any Place Where you are Going to Deploy Application.

While export Crystal report in Language like English we do not get issue because

by Default that font is installed in your PC(Computer).

But While Developing Report In regional Language we face issues:

  • Having fonts but there are not unicode that will be issue for displaying junk Characters.
  • But will see report on your developing PC (Personal Computer) it look proper but will deploying on server it display junk.

What is Unicode Font ? Why to use them.

Unicode provides a unique number for every character,

  • no matter what the platform,
  • no matter what the program,
  • no matter what the language

This line are Reference from site :

Here in this site you will see all details about Unicode font.

Here I am showing you steps how to Resolve this issue in few steps.

Follow Steps

  1. Create New Application
  2. Step File → New → Project
  3. In Installed Template Select Web → ASP.NET Web Application.
  4. Add Name to it.

    Here is Snapshots with Explanation for Creating New application.

  5. After creating Application Just add Webform and Name it .

  6. Add Crystal Report Viewer to Page to display report and Also adding Button to Export

    to Crystal report in to Pdf.

    Here I am providing code for of .aspx page.

    Tools used:

    • Button.
    • Crystal Report Viewer.

    <html xmlns="">

    <html xmlns="">
    <head runat="server">
    <form id="form1" runat="server">
    <div style="text-align: center;">
    <asp:Button ID="Button1" runat="server" Width="150px" Height="50px" Text="Export to Pdf" OnClick="Button1_Click" />
    <div style="text-align: center;">
    <asp:Button ID="Button1" runat="server" Text="Button" />
  7. Add CrystalReport
    • Selecting reporting tools from installed templates
    • After selecting you can see crystal report with visual C#
    • Just select it and name it.

    After this Just new Window will Popup for selection.

    • In popup you will find 3 option to develop it.
    • That Select Blank report.

  8. To Crystal-report I am just Binding Stored procedure.
    • I have just Created table with Name DOIUsertemp.
    • For storing charater of Unicode I have given datatype of it to Nvarchar.

    In Table I have Marathi Inserted Unicode Values to display on Report.

    [ One of Regional Language in India ]

    Data. Create Table.

    View of Table. [ This is Snapshot of Record in Table DOIUsertemp in Marathi.]

    View of Stored procedure

    [ Created Stored Procedure for get values from database and displaying on report ]

    [ This is Snapshot of crystal report with store procedure Fields.]

  9. In this step I am going Dragging Fields on Report from Stored procedure.
  10. After Dragging fields on report i am going to show you how to select font.


    1. Select the Drag Field on Crystal-report .
    2. select Font From above Header which we want to use. (Regional Language Font and MustUnicode).
    3. For Marathi I am going to Select Mangal.
    4. You Can select your own Font according to your need.

    [ This is Snapshot while Selecting in Marathi Font.]

    [ This is Snapshot of Perview Crystal report in Marathi.]

  11. After that just save report.
  12. Now just We Need to write Code for Binding Report and Exporting Report .
  13. Binding Report on load.

    Here I am Providing Code for Binding Crystal Report on Load Event.

    protected void Button1_Click(object sender, EventArgs e)
    SqlCommand cmd = new SqlCommand("Usp_GetUser", con); // calling for Exporting Records cmd.CommandType = CommandType.StoredProcedure;
    SqlDataAdapter da = new SqlDataAdapter();
    da.SelectCommand = cmd;
    DataTable datatable = new DataTable();
    da.Fill(datatable); // getting value according to imageID and fill dataset
    // creating object of crystal report 
    ReportDocument crystalReport = new ReportDocument(); 
    // path of report
    // binding datatable 
    CrystalReportViewer1.ReportSource = crystalReport;
    crystalReport.ExportToHttpResponse(CrystalDecisions.Shared.ExportFormatType.PortableDocFormat, Response, true, "PersonDetails");

Here is Output for Marathi Data after exporting report with no junk Character.

For Hindi Language.

Same Process is required for Developing Crystal in Hindi .

Also Just Change the Font to Hindi while Creating Report its

On button click use same Code used for Marathi to exporting report.

Done. For Demo in table I have Inserted Hindi Record.

View of Table. [ This is Snapshot of Record in Table DOIUsertemp in Hindi.]

Selecting Hindi Font .

[ This is Snapshot while Selecting in Hindi Font.]

Final Out put for Hindi Data after Exporting.

For Arabic Language.

Same Process is required for Developing Crystal in Arabic .

Also Just Change the Font to Arabic while Creating Report its Done.

Main point you can install any other font of Arabic and develop but Font must be Unicode. For Demo in table I have Inserted Arabic Record.

View of Table. [ This is Snapshot of Record in Table DOIUsertemp in Arabic.]

Selecting Arabic Font

[ This is Snapshot while Selecting in Arabic Font.]

Final Out put for Arabic Data.

On button click use same Code used For Exporting Marathi Crystal Report.

Completed My Solution.

Programmer For Sharing Knowledge and Gaining Knowledge

Making People Life Easy


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

saineshwar bageri
Software Developer Mahaonline LTD
India India
Indian Software Developer and MVP from c-sharpcorner working on .Net Web Technology
( , C# , Sqlserver , MVC , Windows ,Console Application, javascript , jquery , json , ORM Dapper) and also freelance developer.

You may also be interested in...

Comments and Discussions

QuestionQuestion about font Pin
Member 131689615-May-17 20:08
memberMember 131689615-May-17 20:08 
QuestionWhat for Embedded font. Pin
Member 131689614-May-17 4:28
memberMember 131689614-May-17 4:28 
Praisethanks Pin
jihad anwar28-Jul-16 20:39
groupjihad anwar28-Jul-16 20:39 
AnswerGood one, my +5 Pin
.NET DJ4-Feb-15 7:15
professional.NET DJ4-Feb-15 7:15 
GeneralRe: Good one, my +5 Pin
saineshwar4-Feb-15 17:16
membersaineshwar4-Feb-15 17:16 
QuestionVery nice article... really helpful. Pin
laxmanppatil25-Mar-14 19:26
memberlaxmanppatil25-Mar-14 19:26 
AnswerRe: Very nice article... really helpful. Pin
saineshwar20-Apr-14 18:51
membersaineshwar20-Apr-14 18:51 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

Permalink | Advertise | Privacy | Terms of Use | Mobile
Web02 | 2.8.170525.1 | Last Updated 25 Mar 2014
Article Copyright 2014 by saineshwar bageri
Everything else Copyright © CodeProject, 1999-2017
Layout: fixed | fluid