data Expression in Page header

  • Hi,

    I want to create page header that will show up on all pages. In page header I add a text box and right-click and go to expression. I want to reference a field here so I type: Fields!col1.Value. But there are no values in the "Fields" category below the expression area. When I click on the "Fields" category, i see a message on the right "Report item not linked to a dataset.". How Do I reference a field from the Page header?

    Thanks.

  • The problem is when you have a table of results, you will have multiple values from a single field. Your textbox in the header does not know which of these values to use. You can try using either a single row dataset for your header textbox(never tried this, not sure it will work), or maybe set a parameter and use the parameter in your textbox.

  • Hi DBowlin,

    Thank you so much for your response. I am new to SSRS. How do i set a parameter?

    Thanks.

  • Hi DBowlin,

    If I go to Report Properties and try to add a variable, want to select a field for a value, but "Fields" are empty.

    Thanks.

  • ramadesai108 (9/15/2010)


    Hi DBowlin,

    Thank you so much for your response. I am new to SSRS. How do i set a parameter?

    Thanks.

    In the report data dialog, right click the Parameter folder and choose add parameter.

  • ramadesai108 (9/15/2010)


    Hi DBowlin,

    If I go to Report Properties and try to add a variable, want to select a field for a value, but "Fields" are empty.

    Thanks.

    Perhaps you should look under dataset.

  • Thank again. The dataset only give you either a first value or a sum of values, so that cannot work. I created an internal paramater and tried to use it in page header but it does not change the value from page to page.

  • Please explain in better detail the type of data you want in the textbox in the header, and how and why you want it to repeat and change on each page.

  • I have a tablix which has 4 header rows. I have a details section where Stored procedure is showing 7 different types of headings. In preview the headers are showing up on each page because all 7 sections for a particular division fits in one page. but when i export to PDF, the last section out of those 7 does not fit into the same page so it shows up on a new page. On this new page the header is missing.

    So I tried to create page header and put all 4 tablix header rows in there, but the page header shows only the first occurence and it does not refresh from page to page.

    I am thinking of create a new group on top of the header group and make it visible only if the section is category. I can select page break between each instance of the group for this blank group. What do i need to put in the code expression?

    Thanks for your time

  • Did you go into the Grouping (Advanced Mode) pane and set RepeatOnNewPage = True and KeepWithGrou = After for the header row of your tablix?

  • I am using studio 2008 so i do not have the options:

    RepeatOnNewPage or KeepWithGrou in Grouping (Advanced Mode) pane

    In that pane the options that I have are:

    Recursive Parent and Document Map

  • You misunderstand. I am not talking about the Group Properties dialog. I am talking about the grouping pane.

    In VS2008 the grouping pane is typically a thin horizontal pane just above the output pane (when it is showing). The grouping pane has a small drop down arrow on the far right of the top. Click it and choose Advanced Mode. Then you click on the appropriate row group, usually the outermost/uppermost static row. Then you look at its properties, and you will see the settings I mention.

  • Hi DBowlin,

    Yes, that's exactly how I understood. When I right-click on a group in the group pane, click on Group properties, click on advanced, I see "Recursive Parent" and "Document Map". I am using studio 2008 professional edition.

    Thanks.

  • You are close, but you are still NOT looking in the right spot.

    You are looking in the Group Properties dialog. I am talking about the properties window (f4). Personally I have the properties window docked on the right side of the screen, you cannot dock the Group Properties dialog box.

    Also, you will probably need to make the setting on one of the "static" rows (usually the very top static row) in the grouping pane to get your repeating headers.

    So, Left click on the row (most likely a "static" row) in the Advanced Mode of the Grouping Pane then go to the Properties window (not the Group Properties dialog) and you will see the settings you need.

    I attached a picture, hopefully that will help you find what I am trying to tell you about.

  • Hi DBowlin,

    Thank you so much for taking time to create a bitmap for me. I truly appreciate it. I don't have any static rows for headers, they are populated thru stored procedure. Any way, i think that my problem is that when i view the report the headers are there on each page (in this example there are 2 pages in view), but when i export to PDF it shows 3 pages, so the header is not showing up on the 3rd page. This seems to be a known issue and nothing can be done about this.

    Thanks again for your help.

Viewing 15 posts - 1 through 15 (of 19 total)

You must be logged in to reply to this topic. Login to reply