SSRS Formatting question

  • Hello all,

    I'm trying to have the year 2011 show above all columns in my report. Right now, it's simply showing once to the far left of the column. I've included a screenshot of what it looks like now. Just resize to 100%, my default is acting screwy. Anyone have any suggestions?

    Thanks

  • Not exactly sure what you are trying to accomplish. The screen shot shows a 2011 off to the right at the top of the report body.

    If you want to to group the results by the Year value from some date field, create a Column Group on that field, group on DatePart("yyyy",Fields!DateField.Value)

    If you want the 2011 centered above the other columns, merge all of the fields on the row into one and center the text.

    If for some reason you want to show the value 2011 at the top of each column, add it to each column, or hopefully a field with the YYYY value.

    [font="Courier New"]Looking for a Deadlock Victim Support Group..[/font]
  • Hello,

    Sorry for the late repsonse. Didnt check this much over the weekend. I apologize, you are correct about the 2011 showing to the RIGHT on the report. And yes, I'm trying to have the 2011 year show above all columns but I'm not sure how to do it. When I try to add the YEAR to all columns, it simply stacks the year to the right of the report. I'm obvisouly doing something wrong, I'm just not sure what it is.

  • Ok, I've experimented with a the GROUP by function and can get the YEAR to show on all columns, but below the column header (State Aid, Local Receipts, Other Revenue, etc). When I pull the the row to the top, it again just shows YEAR once all the way to the right. I'll keep playing with it until I figure it out, but if you got a simple solution, I'm all ears!

    Thanks!

  • Can you post a shot of the Design view rather than the preview.

    To me it looks like the top row might be all merged cells, and aligned right.

    If you have this =Fields!YearField.Value

    In every column, I can't see why it wouldn't display in every column

  • Hello,

    Thanks for responding. I've attached the Design View, rather than the report preview.

    Please keep in mind that I'm dropping my data into a MATRIX table, and NOT a TABULAR table. That probably has something to do with it, huh?

    Mike

  • Do you want 2011 to appear above each column, so that you 2011 is part of the title of the column? Or, do you simply want 2011 centered above all the columns?

  • Centered above all columns.

  • I apologize. I want it centered above EACH column.

  • We can't see a whole lot of detail on your screenshot, but it looks like you have the year in one big merged cell, and the text is set to right justify.

    If you split the cells in the row with the year, you can add the year field to each of the columns.

    [font="Courier New"]Looking for a Deadlock Victim Support Group..[/font]
  • Hi, in a matrix there are both column and row groups.

    Where you have the "=fields!FISCAL_YEAR.value" , (I can't tell because the matrix is not highlighted) but it's either a column group, grouped on the year, or its a big merged cell. Since it's a matrix I'll assume you have a 'year' column group.

    If you are expecting the report might be used to show multiple years, then certainly keep the group, but if you want year to display above every column, then every column needs somehow to include the year field value in the top of it.

    Here are 3 ways you might do it:

    You might right click on the row header and insert another row above the row with your headings (State Aid, Local Receipts etc). You could then put "=fields!FISCAL_YEAR.value" into each of those cells.

    You then don't need the top row because you don't need to display the year twice, but you might still need the group, so just delete that top row without deleting the group(s).

    Alternatively, right-click on that top cell and choose 'Split Cells'. Make sure to have the cell selected and not be clicked into the cell or you won't see the option. You can then repeat the expression "=fields!FISCAL_YEAR.value" in each of the cells.

    A third option would be that if you don't want an extra set of cells to display year, then you can combine it with your current headings.

    e.g. you can right-click on the 'State Aid' cell and modify the expression to read:

    =fields!FISCAL_YEAR.value + " State Aid"

    That would look like this: 2011 State Aid (note the space in the beginning of the string " State Aid")

    Or you could add a new line between the year and the heading

    =fields!FISCAL_YEAR.value + chr(10) + chr(13) + "State Aid"

    character 10 is a carriage return and character 13 is a line feed (from old typewriter terminology). Together they mean the following part is written to the beginning of the next line down. In that case you shouldn't have a space at the beginning of "State Aid".

    --The downside of this last option is that in the design view all the headings won't be obvious anymore and will all read "<<Expr>>".

    I found that getting to grips with column groups is not straight forward, and not as intuitive as row groups, especially when you start combining them.

Viewing 11 posts - 1 through 10 (of 10 total)

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