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. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

How to set Text alignment for a specific PDFGrid''s cell?

Thread ID:





97290 Nov 15,2010 01:25 PM UTC Nov 16,2010 05:30 AM UTC ASP.NET Web Forms (Classic) 1
Tags: PDF
Asked On November 15, 2010 01:25 PM UTC


I try to center the Text with the code below; however it does not work.

PdfGrid grid = new PdfGrid();

PdfGridRow row;

row.Cells[1].Style.Font = new PdfStandardFont(PdfFontFamily.Courier, 20, PdfFontStyle.Bold);

row.Cells[1].Style.StringFormat = new PdfStringFormat(PdfTextAlignment.Center);

row.Cells[1].Value = ("CENTER TEXT");

How do I center a text in a specific cell?


Priyadharshini J [Syncfusion]
Replied On November 16, 2010 05:30 AM UTC

Hi Kim,

Thank you for your interest in Syncfusion proudcts.

We have placed a sample in the link below to align the text to the center of a specific cell.

Kindly try this and let us know if you have any queries.



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.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon 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.Close Icon