score:1
Accepted answer
Below is a working code for the required result:
let options = HIOptions()
let chart = HIChart()
chart.events = HIEvents()
chart.events.load = HIFunction(jsFunction: "function() { this.tooltip.refresh(this.series[0].points[2]); this.tooltip.refresh(this.series[0].points[4]); this.tooltip.refresh(this.series[0].points[6]); }")
options.chart = chart
let tooltip = HITooltip()
tooltip.formatter = HIFunction(jsFunction: "function() { return '...'; }")
options.tooltip = tooltip
let plotOptions = HIPlotOptions()
plotOptions.column = HIColumn()
plotOptions.column.point = HIPoint()
plotOptions.column.point.events = HIEvents()
plotOptions.column.point.events.mouseOver = HIFunction(jsFunction: "function() { let tooltip = chart.tooltip; tooltip.update({ formatter: function() { return 'New content!' } }) }")
options.plotOptions = plotOptions
let column = HIColumn()
column.data = [4, 3, 5, 6, 2, 3, 7, 9, 12, 15, 2, 4, 6]
options.series = [column]
score:0
Slight change in the accepted answer as graph need little time to load so setting timeout of 200ms, if data is more increase the time accordingly
let options = HIOptions()
let chart = HIChart()
chart.events = HIEvents()
chart.events.load = HIFunction(jsFunction: "function() { var self = this; setTimeout(function(){ self.tooltip.refresh(self.series[0].points[2]); }, 200); }")
options.chart = chart
let tooltip = HITooltip()
tooltip.formatter = HIFunction(jsFunction: "function() { return '...'; }")
options.tooltip = tooltip
let plotOptions = HIPlotOptions()
plotOptions.column = HIColumn()
plotOptions.column.point = HIPoint()
plotOptions.column.point.events = HIEvents()
plotOptions.column.point.events.mouseOver = HIFunction(jsFunction: "function() { let tooltip = chart.tooltip; tooltip.update({ formatter: function() { return 'New content!' } }) }")
options.plotOptions = plotOptions
let column = HIColumn()
column.data = [4, 3, 5, 6, 2, 3, 7, 9, 12, 15, 2, 4, 6]
options.series = [column]
Source: stackoverflow.com
Related Query
- HighCharts(iOS) -How to show tooltip by default at only some positions
- How to show tooltip of bars as default in highcharts gantt?
- How To Show Tooltip In Sparkline Chart From Code
- How to show only integer values on yAxis of HighChart?
- Highcharts - only show tooltip when hovering directly on point
- How to show gridlines only on 0 on the yAxis in highcharts?
- How to show only specific x-axis values on datetime axis in Highcharts
- HighCharts area graph - show tooltip only on hover of marker
- how to pass datalabels along with data to show it in tooltip in highchart
- Is there some way to only show the PNG option in exporting.csv?
- How to show only weekday on xAxis with Highcharts?
- how to show data label only on drilldown pie?
- How to edit tooltip in Highcharts C# code
- how to show cross hair in highchart always by default
- how to show cross hair in highchart always by default
- how to use highcharts tooltip formatter in python code
- Why does this Highcharts graph only show tooltip for the first and last nodes?
- How to show open, close, high and low in tooltip when the chart type is 'line' in highstocks?
- How to display tooltip only for last point?
- How to show xAxis label in tooltip in a Highcharts area chart?
- How to show only one pair of linked Highcharts series at a time
- Why Highcharts box only show with some position
- How can I show only one x-axis in synchronous chart highchart
- how to show one more array in the tooltip using highchart?
- How to show values in Highcharts tooltip other than x and y when data points are too high?
- How to show other point property in bubble highcharts using tooltip
- How to add a vertical plot line in multiple line series and show the tooltip on Plot line in highchart
- Show only some series in HighCharts spline chart
- How do I toggle off some specified series by default in HighChart?
- How to show only the last 100 candlesticks or hide the first 50 candlesticks in Highcharts Stock Chart?
More Query from same tag
- Adding multiple dynamic series and axes via JSON into Highcharts
- Offline exporting a Highcharts chart using an external button
- How to make json object for this type in c#?
- Graphs backround on Iexplorer after Deploying it on the server
- Highchart Export chart not returning image in IE8 or IE9
- Remove spacing on a HighChart graph?
- Spider Chart (High Chart) in rails with Prawn PDF How to generate?
- Highcharts Export Server on AWS Lambda
- Chart not resizing according to it's container Highcharts reactjs
- Columns not stacking up with HighCharterR in the tooltip
- Custom HTML marker in Highmaps
- I have correct XPath but selenium is not clicking in Highcharts popup
- Highcharts not showing up
- Odd Highcharts interaction between pointRange of two columns and xAxis.max
- Loading JSON data in Ruby on rails to use HIGHCHARTS
- Generating PDFs when JavaScript is being used
- How can I force multiple y-axis in Highcharts to have a common zero
- HighCharts : Xaxis lables misplaced
- Highcharts bar chart overlay
- renderer.text not working in gevgeny/angular2-highcharts
- Difference between highcharts and highstock during real time trace and xAxis with max value
- How to reverse colors order for the first label?
- Negative values causes wrong y-axis highcharts
- Adding a pattern fill to a black and white column graph in Highcharter
- Change the color of bar on condition in highcharts
- yAxis formatter sometimes receives 0 for this.value
- How to change JSON Format For load data to Highchart
- create a donut chart using highchart using jquery json object
- Highchart graph for continues status data in bar like timeserise
- Highcharts - Ignore totals row in DataTable