cancel
Showing results for 
Search instead for 
Did you mean: 

Help with Capturing Business Graphics data point

Former Member
0 Kudos

Hi,

I created a BusinessGraphics UI element with SimpleSeries and assigned eventId for the categories and data points. I am able to get the series that is clicked through the event but I would like to know which point (value) is clicked as well.

The steps I followed are

1. Created BG UI element, category and SimpleSeries

2. Assigned eventIDs

3. Created an action class and mapped it to the UI element

4. Code in wdDoModifyView is

if (firstTime)

{

IWDBusinessGraphics chart = (IWDBusinessGraphics) view.getElement("bgCSB");

chart.mappingOfOnAction().addSourceMapping("id", "pointID");

}

5. Implemented action class with one parameter (pointID) and able to get the value.

Can someone help me to get the data point values from the user click.

Appreciate your help.

Thanks,

Kalyan

View Entire Topic
Former Member
0 Kudos

You have done everything right, except I don't think you can do this with simple series.

Create something like this:

in the context:

series-> (this node can be with 1..1 cardinality and 1..1 selection)

points->

label (string)

value (int)

pointId (string)

in the business graphics:

create one series (not simple one) and add to it one point of numeric type.

in the properties of business graphics bind seriesSource to series context.

Series: bined poitSource to series.points

Series_points: bind eventId to series.points.pointId

bind label to series.points.label

bind valueSource to series.points

Values (these are the numeric values): bind value to series.points.value

in wdDoModify method do the same thing as you have done already.

Now, when you click on a point you will receive in your event in pointId variable the pointId context attribute value.

Best regards,

Anton

Former Member
0 Kudos

Hi Anton,

Thanks a lot for the reply. It now works

Once again, thank you very much for your help.

Thanks,

Kalyan