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 design header/details/Footer in report

Thread ID:





126960 Oct 18,2016 07:06 PM UTC Oct 20,2016 12:39 PM UTC ASP.NET Web Forms 1
Tags: ReportViewer
Asked On October 18, 2016 07:06 PM UTC


How to design header,details, and footer in report and barcodecode also need to show at header

   private void LoadReport()



            List<ReportDataSource> rptDatasources = new List<ReportDataSource>();


            ReportDataSource rptDatasource1 = new ReportDataSource();

            rptDatasource1.Name = "DataSet1";

            rptDatasource1.Value = bindstudent();



            ReportDataSource rptDatasource2 = new ReportDataSource();

            rptDatasource2.Name = "DataSet2";

            rptDatasource2.Value = headerrpt();





            this.ReportViewer1.DataSources = rptDatasources;

            this.ReportViewer1.ReportServiceUrl = VirtualPathUtility.ToAbsolute("~/api/RDLCReport");





        // header report

        private List<divisions> headerrpt()



            List<divisions> division = new List<divisions>();


            division.Add(new divisions { year = "2015", date = DateTime.Parse("05/05/2015"), barcodecode = "00007" });



            return division;







        class divisions



            public string year;


            public DateTime date;


            public string barcodecode ;










// Details Report


        private List<Students> bindstudent()



            List<Students> stud = new List<Students>();


            stud.Add(new Students { name = "basil", studentID = "100001", address = "25,st.charles st" });


            stud.Add(new Students { name = "sam", studentID = "10002", address = "33,wellow st" });


            stud.Add(new Students { name = "rosee", studentID = "100003", address = "31,Feter st" });


            return stud;







        class Students



            public string name;


            public string studentID;


            public string address;






Attachment: report_d0ed0766.rar

Yuvaraj Devarajan [Syncfusion]
Replied On October 20, 2016 12:39 PM UTC

Hi Pratheep, 
Thanks for contacting Syncfusion support. 

How to design header,details, and footer in report 
We can add the header and footer in Report design surface area itself by right clicking the report surface and choose the insert option and select the page header or page footer option. Then we can add the Report Items in page header and footer surface by right clicking the page header and footer surface and choose the insert option and add the Report items.   
Please refer to the below MSDN documentation for more detail, 

 barcodecode also need to show at header 
We have generated the barcode using our “Syncfusion.Pdf.Base” assembly with code modules and pass/set the generated barcode base64string to image by using field expression (=Code.Convert("ABCD 12345")).   

Code Modules: 

Reference to Assemblies and classes. 

We have prepared the sample and it can be downloaded from below location, 
Note: In your shared sample, you have not added the WebAPI restful service to process the report. In ReportViewer control, the report is processed in server side using WebAPI controller. So, add the WebAPI restful service and config the WebAPI controller in global.asax file.   
Please refer to the below UG documentation link to create the sample in ASP.NET web platform, 

You can obtain the ASP.Net ReportViewer samples from the below build installed location,   

Yuvaraj D. 


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