get(String propertyName)

Returns the specified property of buttons.


Parameters:
        propertyName: Name of the property

Example: stockChart.rangeSelector.buttons.get(“range”);

Note:
  • You can refer to Buttons Element for complete list of properties available.
  • StockChart should be rendered before you can use get method.

var stockChart = new CanvasJS.StockChart("container",
{
 .
 rangeSelector:{
   buttons: [
     .  
      //Buttons properties
     .
   ]
 }
 .
 .
 . 
});
stockChart.render();

console.log(stockChart.rangeSelector.buttons.get("rangeType"));

Properties accessible via get method

Please refer to Buttons Element for the complete list of properties that can be accessed via get method.




Try it Yourself by Editing the Code below.


  Also See:    



If you have any questions, please feel free to ask in our forums.