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
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

How to apply Alternating Row style while printing SfDataGrid?

Platform: WinRT |
Control: SfDataGrid |
Published Date: February 9, 2015 |
Last Revised Date: January 19, 2016 |
.NET Framework: 4.5
Tags: printing

SfDataGrid allows you to customize the DataGrid while printing, with the help of custom print manager that is derived class from GridPrintManager of SfDataGrid. Using custom print manager you can customize the row style, row height, column width, header text, etc. Also you can apply alternating row style by overriding the GetPrintGridCell method in the CustomPrintManager class and set the background to PrintGridCell.

The following code example explains you how to create Custom Print Manager Class and override GetPrintGridCell method to apply the alternating row style.


You can set the above customized print manager to SfDataGrid.PrintSettings.PrintManagerBase property as illustrated in the following code example.


The following screenshot displays the print preview of SfDataGrid with Alternating Row Style.

Figure 1: Print preview of SfDataGrid with Alternating Row Style


Sample Links:




You must log in to leave a comment

Please sign in to access our KB

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

Up arrow icon

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

Live Chat Icon For mobile