Jump to content
JChartFX Community

nz1975

Members
  • Posts

    2
  • Joined

  • Last visited

Everything posted by nz1975

  1. OK,this is a clear,but I need a refresh data so i have this function and she works: " function onLoadDoc() { var vl1; var vl2; var vl3; var val1; var val2; var val3; var chart1; chart1 = new cfx.Chart(); chart1.setGallery(cfx.Gallery.Lines); chart1.getLegendBox().setDock(cfx.DockArea.Bottom); val1 = document.getElementById('v1').value; <-v1,v2,v3 are text input (number) val2 = document.getElementById('v2').value; val3 = document.getElementById('v3').value; vl1 = parseInt(val1); vl2 = parseInt(val2); vl3 = parseInt(val3); var data=[{ "Label": "+18", "text": vl1 }, { "Label": "0", "text": vl2 }, { "Label": "-15", "text": vl3 }]; chart1.setDataSource(data); var chartDiv = document.getElementById('ChartDiv1'); chart1.create(chartDiv); } //*****END OF FUNCTION***** """" This function works but I need next:User change V1,V2 AND V3 (number value) and press a button,then i need just to refresh data in same chart
  2. I'm a n00b so I have a two question: 1. How could I clear my data from chart? (or refresh?) 2. When I set data on my chart I have a data,which I'm not enter. I use your sample code from this site. Thanks
×
×
  • Create New...