|
|
Question : Dynamic column width using Can Grow/Can Shrink
|
|
Hello Experts,
I have a table in Reporting Services 2005 that contains potentially 30 columns ... however, they are all set to not show if they contain no data. In reality, the table generally will show no more than 12 or so columns and can fit easily on a landscaped page. The report is working fine and the export to Excel is also working fine - but if printing or exporting to PDF, all the blank pages caused by the original width of the table are included. That is, the table with its full 30 columns is a lot wider than the actual result the user sees, and that width is taken up with blank pages. At design time, I cannot alter the width of the table because even if I make all the fields small enough and then set them to "Can Grow" - they don't grow and I end up with a squished-looking mess. Which is frustrating because I would have thought that's the whole point of "Can Grow" and "Can Shrink".
Has anyone got any idea how we can get around this issue?
Thanks in advance, GHL
|
Answer : Dynamic column width using Can Grow/Can Shrink
|
|
Can grow/shrink refers to cell/row height, not width.
In your scenario I would limit the number of columns but make the contents conditional. So if showing FieldA and FieldB are mutually exclusive but based on a parameter setting you could have; =IIf(Parameters!myFormatChoice.Value = "A", Fields!myFieldA.Value, Fields!myFieldB.Value)
You'd have to do similar conditional checks in group totals as well but it will work and you then can layout the screen more realistically.
|
|
|
|
|