4
Reply

Hindi text in to ItextSharp Pdf

Rahul Bansal

Rahul Bansal

Feb 4 2015 3:59 AM
2.5k
I am Fetching Hindi text from database and  displaying it into runtime pdf using Itextsharp but at the time of display, text is not in proper hindi.
 
 
BaseFont bf = BaseFont.CreateFont(HttpContext.Current.Server.MapPath("font\\ARIALUNI.TTF"), BaseFont.IDENTITY_H, BaseFont.NOT_EMBEDDED);
iTextSharp.text.Font font = new iTextSharp.text.Font(bf, 8, iTextSharp.text.Font.NORMAL); 
TblGrid.AddCell(new PdfPCell(new Phrase(PartA_9to23[i, 1], font)) { BorderWidth = 1, HorizontalAlignment = 0, FixedHeight = 18f }); 

Answers (4)