This is a migrated thread and some comments may be shown as answers.

Export Rad Grid to Excel,pdf and MS word with Headers

8 Answers 156 Views
Grid
This is a migrated thread and some comments may be shown as answers.
AHSAN
Top achievements
Rank 1
AHSAN asked on 24 Jan 2011, 05:21 PM
Thanks 

8 Answers, 1 is accepted

Sort by
0
Daniel
Telerik team
answered on 24 Jan 2011, 09:15 PM
Hello Sean,

What kind of header you have in mind? Column header or page header? In the second case, you could add your own custom HTML code in the GridExporting / PdfExporting events.
If you post some more information I will be able to provide more to-the-point answer.

Regards,
Daniel
the Telerik team
Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
0
AHSAN
Top achievements
Rank 1
answered on 24 Jan 2011, 10:44 PM
Thanks
0
AHSAN
Top achievements
Rank 1
answered on 25 Jan 2011, 12:29 AM
Thanks
0
Daniel
Telerik team
answered on 27 Jan 2011, 04:49 PM

Sample code:
protected void RadGrid1_PdfExporting(object sender, GridPdfExportingArgs e)
{
    e.RawHTML = "<div style='color: #606010; background-color: #88afea; font-weight: bold;'>this is a test</div>" + e.RawHTML;
}

Let me know if you need more information.

Regards,
Daniel
the Telerik team
Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
0
AHSAN
Top achievements
Rank 1
answered on 27 Jan 2011, 05:19 PM
Thanks
0
Daniel
Telerik team
answered on 01 Feb 2011, 10:58 PM
Hello Sean,

You can add the desired number of headers by modifying the html code however this custom content will remain static - i.e. it will displayed on the first page only.

Best regards,
Daniel
the Telerik team
Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
0
Mark
Top achievements
Rank 1
answered on 17 Jul 2012, 12:50 PM
Is there a way to add a header appear on every PDF page?  In the Header I like to add images or logos of the firm.

Thanks

Mark
0
Daniel
Telerik team
answered on 20 Jul 2012, 12:42 PM
Hello Mark,

The only easy way to do this would be to put the desired image in the command item or in the header item. It will not appear on the top of the page however, but rather on the top of the grid.

Best regards,
Daniel
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Tags
Grid
Asked by
AHSAN
Top achievements
Rank 1
Answers by
Daniel
Telerik team
AHSAN
Top achievements
Rank 1
Mark
Top achievements
Rank 1
Share this question
or