I've implemented the technique describe in the two videos under FP11_DLGCHART5. The chart data that I'm using is a numeric value, but the hover message displays it without any formatting, so the numbers look like: 123456.12255
I'd like the format to be (at least) like: 123,456.12, but ideally I'd prefer the format like: $123,456.12 if possible.
I'm wondering if anyone knows how to format the number or style of the chart.value that is being called with the JS function; I'm a complete novice. I'm using the code provided from the component template that is provided with the videos.
This is the code for the JavaScript Function:
And this is the code from the Chart Events onMouseOver:
Regards,
Mel
I'd like the format to be (at least) like: 123,456.12, but ideally I'd prefer the format like: $123,456.12 if possible.
I'm wondering if anyone knows how to format the number or style of the chart.value that is being called with the JS function; I'm a complete novice. I'm using the code provided from the component template that is provided with the videos.
This is the code for the JavaScript Function:
Code:
function positionChartBubbleHelp(ele,event) { var coords = $e.getCoors(event); var offsetY = -10; var offsetX = 10; ele.style.top = (coords.clientY + offsetY) + 'px'; ele.style.left = (coords.clientX + offsetX) + 'px'; }
Code:
/* Your Javascript code can reference these variables: chart.seriesNumber (0 based), chart.pointNumber (0 based point number in the series), chart.value (value for the point) chart.xvalue (value for the x-axis value (used in x-y and scatter charts) legend.label (text label on the legend - if the chart has a legend) point.label (text for point label) */ var msg = 'Amount: '+ chart.value; var ele = $('floatingMessage'); ele.innerHTML = msg; ele.style.display = ''; positionChartBubbleHelp(ele,event);
Mel
Comment