This topic is locked
[SOLVED]

Add data name to chart title

11/28/2022 4:37:34 PM
ASPRunnerPro General questions
C
Cmdias author

Hi Guys, I managed to get my search and charts working ok... but now i was wondering how to get the data name in the chart title...

I would like the chart title to always be the NAME for the valued that i searched for. (in red sqaures in scree shot)

I already know the chart.title in the chart modify page but cant seem to find a way to grab the searched value adn add it to the tile...

Here's a screen shot
img alt

thx!

admin 11/28/2022

I recommend checking ChartModify event. This is how you can customize charts.

C
Cmdias author 11/29/2022

Yes i did look into that.. but i'm worth zero with coding.... and this is the last point so i can close this mini project.

i'm just trying to get an entry from current record in search and add it to the chart title ... was looking ito this but it doesnt seem like the symtax

set data = pageObject.getCurrentRecord()
response.write data("Location")

so if i searched for a LOCATION called MACHINE1 that the graph title is Data for MACHINE1 ... as you can see my serach is done via radio buttons.

thx!

admin 11/29/2022

Yes, your syntax doesn't make any sense. You cannot guess the syntax.

Check Example 5. Customize the chart title in that article. Start with something that is small and expand from there.

Or hire someone to do this for you.

C
Cmdias author 11/29/2022

Looks like i'll pass the ball over to some one! i'll stick with networking lol

thx!

jadachDevClub member 12/1/2022

I just did something similar in ASPRunner.Net. I am using a dropdown opposed to filter.

Chart Page Javascript Chart Modify

if(proxy['ChartTitle']==null)
{
chart.title({text: "All Surgical Areas"});
}
else
{
chart.title({text: proxy['ChartTitle']});
}

Chart Page Before Display

dynamic srchObj = SearchClause.getSearchObject("dbo.BI_ORCurrentDataHistory_Raw");
pageObject.setProxyValue("ChartTitle", srchObj.getFieldValue("surgical_area"));