Below is the code for exporting report to PDF
format.
In the below function following parameters stands for :
viewer =Report Viewer Control object
exportType=export format say "PDF"
reportsTitle=Report name/title while exporting.
public bool ExportPDF(ReportViewer viewer, string exportType, string reportsTitle)
{
try
{
Warning[] warnings = null;
string[] streamIds = null;
string mimeType = string.Empty;
string encoding = string.Empty;
string extension = string.Empty;
string filetype = string.Empty;
// just gets the Report title... make your own method
//ReportViewer needs a specific type (not always the same as the extension)
filetype = exportType == "PDF" ? "PDF" : exportType;
byte[] bytes = viewer.ServerReport.Render(filetype, null, // deviceinfo not needed for csv

Former memberPosted Dec 14, 2014, 11:53 PM
I want to know how to print tables in rdlc that is in landscape
Former memberPosted Dec 14, 2014, 11:52 PM
Nice work....!!!!!!!!!!!!