none
How to programmatically scale ReportViewer? RRS feed

  • Question

  • Hello,

    I have some questions about WinForms.ReportViewer.
    1. Can I access report toolbar? And if can, how?
    2. Is there any way to programmatically scale chart so that min and max of x- and y-axes would be different than initial?
    3. I have to display and hide lines in chart at runtime. Would be nice if I can display checkboxes in the legend. Anyway, is there any way to control visibility of lines at runtime?

    Thanks
    Tuesday, August 14, 2007 1:37 PM

Answers

  • So, I have found answers on all my questions! Alone...
    2. Use of series filters is not good idea. It cut boundary points... I have use report parameters to restrict points by using scale min & max (X Axis & Y Axis pages).
    Example:
     Scale minimum:  =Parameters!ScaleMinValue.Value
     Scale maximum:  =Parameters!ScaleMaxValue.Value
    3. Hiding of lines I've done by changing value.
    Example:
     =Iif(Filter(Parameters!Ids.Value, Fields!Id.Value).Length = 1, Avg(Fields!Value.Value), 3000)
     This must be written in Edit Chart Value dialog, Value combobox.
     Ids is multistring parameter that contains id to be shown

    Hope this helps if you would have same tasks
    Monday, September 10, 2007 1:03 PM

All replies

  • Well...
    1. I have found toolbar by: reportViewer.Controls.Find("toolStrip1", true);
    2. I think it can be made by report filters only Sad...
    3. In progress
    Small question: where are experts?
    Thursday, August 16, 2007 3:18 PM
  • So, I have found answers on all my questions! Alone...
    2. Use of series filters is not good idea. It cut boundary points... I have use report parameters to restrict points by using scale min & max (X Axis & Y Axis pages).
    Example:
     Scale minimum:  =Parameters!ScaleMinValue.Value
     Scale maximum:  =Parameters!ScaleMaxValue.Value
    3. Hiding of lines I've done by changing value.
    Example:
     =Iif(Filter(Parameters!Ids.Value, Fields!Id.Value).Length = 1, Avg(Fields!Value.Value), 3000)
     This must be written in Edit Chart Value dialog, Value combobox.
     Ids is multistring parameter that contains id to be shown

    Hope this helps if you would have same tasks
    Monday, September 10, 2007 1:03 PM