cancel
Showing results for 
Search instead for 
Did you mean: 

Fetching Data from vizframe based on mouse click

former_member187272
Participant
0 Kudos

Hi experts

I am developing Fiori application using XML views and JS controllers. I am using chart container for displaying charts(SAPUI5 Explored)

here when i click on the bar i need to get the corresponding value on y axis,for example if i click first bar i should get africa, in my view i have

assign selectData="myOnClickHandler"  function for viz:VizFrame and i have defined myOnClickHandler function in my controller,

<viz:VizFrame height="350px" id="idoVizFrame" selectData="myOnClickHandler" uiConfig="{applicationSet:'fiori'}" width="100%"></viz:VizFrame>

Thanks

Accepted Solutions (1)

Accepted Solutions (1)

gill367
Active Contributor
0 Kudos

Set a breakpoint in the "myOnClickHandler" event handler in the developer tool of the browser and explore the parameters present in oEvent.

For example, for chart present at following location

SAPUI5 Explored 

we can fetch the y-axis header using the following

oEvent.mParameters.data[0].data["Store Name"]  this will give "A&A"




Regards,

Sarbjeet Singh

Answers (0)