Today we learn how to create SSRS Report Headers and Footers which are pretty easy but remember SSRS have Report Header only but not Page Headers as available in Crystal Reports.
Let’s quickly make a sample report with Header and Footer. Right click anywhere in report and click Add Page Header and type the header as you wish by adding textbox in it as shown below:
Now let’s create page footer by clicking on Add Page Footer. Here too can be added text box and type the text as you want. But I want Date on right bottom side, page no. on left bottom side of page to be displayed.
To achieve it we need to add formula fields in the text boxes added in page footer also I made some more changes to report by right clicking in Report Header section and then selecting Header Properties and fill the background color as dark green and repeated the same for report footer as shown below:
That’s it for the day..Enjoy
Today we gonna learn how to create static headers on every page of SSRS reports which are not report headers. Observe the below report page 2 which does not have report header since it is visible only on page 1.
To make header visible on every page, follow the below steps:
- Click the Columns Group à Click Advanced Mode as shown below:
- After clicking on Advanced Mode, you find multiple entries in Row Groups and Column Groups as shown below:
Click on Static which is present in Row Groups and browse the tablix member properties named as RepeatOnNewPage = true, KeepWithGroup = After.That’s it. Now execute the report and it is as shown Page1 and page2.
That’s it for the day. Enjoy..:)
Assalamualaykum Wr Br.
Today we discuss few more things of SSRS formatting which pretty simple but I want it to be here for future references.
Lets have a look on below report where report have three columns with name SID, SNAME, STANDARDID which are marked in blue color.
The values of Sid column are at right side which is because of the following property as shown below:
Right click the column and select properties – > Alignment Tab -> Horizontal =Right .
For which all values of Sid and StandardId are aligned to right of the text box.
Now I would change this value to center and which impacts on reports as shown below:
Observe the values of all columns which are aligned to center of each text box of table.
I did the same to headers where alignment property set as “Center” as shown below:
Now observe that there are borders to each cell. There are most reports which does not have borders to each cell. To achieve it, right click the cell -> textbox properties -> Boders -> click on None button as shown below:
After Clicking on OK. The report will be visible as below:
That’s it for now. Enjoy..:)
Assalamualaykum wr br
I was working with migration of crystal reports to SSRS. There are much differences in these two reporting strategies which I am going to focus here.
1. Crystal report would have report header and report footer which displayed on whole report. In addition to it page header and footer does have.
2. SSRS would have only page header and footer which will be displayed on every page. SSRS page header and footer works like report header and footer.
3. To have page header in SSRS report we need to perform some actions which are as follows:
Select a column header, at below there is a columns table with drop down click it which shows advance view,click it which displays static headers next to it. Click the static and press f4 key which displays properties of tablix member there at last a property repeat on every page set it to true and select after option.
Assalamualaykum Wr Br…today we explore the asp.net’s powerful control to display data as in tabular format with built-in Edit, Update, Cancel and Insert options, named as GRIDVIEW. The general syntax of markup is as shown:
<asp:GridView ID=”gridview1″ runat=”server”>
This gridview will not display data because it has not datasource and databind method is called.
Assalamualikum wr br.
Today we discuss about one requirement where data needs to be displayed in GridView from table abc which has more than 2,66,000 records. This was coded to fetch data using DataAdapter on page_load event later it was done pagination from memory using GridView pagination. Later it was reported that memory leakage encountered and pagination is not responding.
Hence it was suggested to retrieve data on demand which means based on page index of gridview, no. of records needs to be fetched from data table.
Also most interesting point is Oracle 11g is being used which does not support Fetch and Limit keywords.
Fetch is used to limit the result set generated from the query. Since we use 11g we need to modify the existing query as below:
|Select * from
( Select p.record_type,
from abc) p
where rownum <= 50 <max_limit>)
where rm >= 10 <min_limit>;
With the help of above modifications I can able to retrieve the records in table data between max_limit and min_limit. Otherwise the rownum would return from records 1 to specified constraint.
That’s all for the day.
Jazakallah khair..Happy Programming..:)