Toad World® Forums

How To Configure Chart to Only Display GroupHeader data in Report Designer

I have a Report containing a Bar Chart, which needs to display data for separate groups.

This bar chart has been placed in the GroupHeader1 band, which has a GroupField set.

But when previewed the report includes six identical bar charts (with all data for all groups), when I expect to see six charts containing only the data for that group.

I’m not sure how to configure this correctly in the Report Designer or Chart Wizard.

Anyone able to help me with this issue.

Thank you in advance.

Regards

David

I searched throught the DevExpress help files and samples did not find any support for this. Sorry.

How many groups do you have? If not alot perhaps you can do something with putting a different filter on several series. The Charts seem to want to display all of result set not at the grouped row level.

Debbie

Hi Debbie,

There are currently six groups requiring separate bar charts. I was trying to create PDF output of two A4 sheets (portrait), which have three bar charts each.

Am I correct in thinking that I will have to create individual bar charts (filtering the data on a specific group)? And place/size these in separate Header bands, so they display as required?

Thank you in advance.

Regards

David

I played around with this a bit and did not solve the issue. I have posted a question on our third party component site.

http://www.devexpress.com/Support/Center/Question/Details/Q426437

Debbie

Hi,

I have the same issue. I’m trying to display charts using my sql query, which use GROUP BY ROLLUP and that sort of things.

I’ve copy/paste the code you’ve found Debbie, but instead of a chart I got blank.

Code :
private void chart1_BeforePrint(object sender, System.Drawing.Printing.PrintEventArgs e)
{
XRChart xrc = (XRChart)sender;

// Gets the current value of the grouping field.
// For the master-detail report use DetailBand.GetCurrentColumnValue in detail part instead.
string filter_value = GetCurrentColumnValue("TERRITOIRE").ToString();

// Clears the filters that may be set before.
xrc.Series[0].DataFilters.Clear();

// Creates and adds a new filter on the data field "TheGroupingField"
// that has the type System.String. 
// The condition is that the data value equals the filter_value parameter.
xrc.Series[0].DataFilters.Add(new DataFilter("TERRITOIRE", "System.String",
    DataFilterCondition.Equal, filter_value));

}

My Chart is “chart1” and TERRITOIRE is the field I group on.

Thank you in advance,

Cordialement,

Pierre