Forum Replies Created by Manoj Mohan

Viewing 15 posts - 676 through 690 (of 796 total)
  • in reply to: Chart changing with data size #26543

    @vb123er951,

    Please take a look at this JSFiddle.

    —-
    Manoj Mohan
    Team CanvasJS

    @gowri,

    There are couple of issue with the code that you have shared.

    1. You need to replace chartType with chart in chartType.options.data[0].type as chartType is referred to dropdown field not the chart object.
    chart.options.data[0].type = chartType.options[chartType.selectedIndex].value;

    2. Below code has to be inside the window.onload function as chart is inside window.onload scope.

    var chartType = document.getElementById("chartType");
            chartType.addEventListener( "change", function(){
            chart.options.data[0].type = chartType.options[chartType.selectedIndex].value;
            chart.render();
    });

    Please take a look at this JSFiddle for the complete code.

    Chart with dropdown to change chart type

    Considering this thread as a duplicate of using drop down how to change charts using user input value and hence closing the same.

    —-
    Manoj Mohan
    Team CanvasJS

    @gowri,

    There are couple of issue with the code that you have shared.

    1. You need to replace chartType with chart in chartType.options.data[0].type as chartType is referred to dropdown field not the chart object.
    chart.options.data[0].type = chartType.options[chartType.selectedIndex].value;

    2. Below code has to be inside the window.onload function as chart is inside window.onload scope.

    var chartType = document.getElementById("chartType");
            chartType.addEventListener( "change", function(){
            chart.options.data[0].type = chartType.options[chartType.selectedIndex].value;
            chart.render();
    });

    Please take a look at this JSFiddle for the complete code.

    Chart with dropdown to change chart type

    —-
    Manoj Mohan
    Team CanvasJS

    in reply to: using drop down how to change charts using user input value #26323

    @gowri,

    Please take a look at this JSFiddle to change chart type based on the value selected from the dropdown. Similarly, you can change chart options based on selected value from the dropdown.

    —-
    Manoj Mohan
    Team CanvasJS

    in reply to: Bug on chartContainer #26322

    @daicc,

    In JavaScript Month starts from 0 (January) and ends at 11(December). So in your case both Date(2019,01,29) and Date(2019,02,01) represents 1st of March hence chart displays two dataPoints on “02-01”. Please take a look at this JSFiddle for working example.

    —-
    Manoj Mohan
    Team CanvasJS

    in reply to: Need to upgrade? #26308

    @jkd_dude,

    We generally recommend everyone to use the latest version of CanvasJS.

    The upgrade process is pretty simple, you just have to replace CanvasJS files. All your existing code will continue to work and changes needed.

    You can check release notes at our blog.

    —-
    Manoj Mohan
    Team CanvasJS

    in reply to: Angular 8, IE 11 Prroblem #26307

    @jackscho,

    It seems to be working fine. In order to run an angular app in IE11, you need to modify Browserslist and TypeScript configuration files. In tsconfig.json, you need to set "target": "es5" and in .browserslistrc file, replace not IE 11 with IE 11 to make angular app compatible with IE11. Please refer this angular docs page for more information.

    If the issue still persists, please share a sample project over Google-Drive or OneDrive reproducing the issue you are facing, so that we can look into your code, understand the scenario better and help you out?

    —-
    Manoj Mohan
    Team CanvasJS

    in reply to: How to plot multiple line graphs on same Chart #26290

    Peter,

    Can you please share a sample project along with sample data over Google-Drive or OneDrive so that we can understand your scenario better and help you out?

    —-
    Manoj Mohan
    Team CanvasJS

    in reply to: Radar Chart #26272

    @9dan7,

    Sorry, we don’t have a definite timeline for Radar Chart as of now.

    —-
    Manoj Mohan
    Team CanvasJS

    in reply to: How to plot multiple line graphs on same Chart #26271

    @welshp2,

    You can render multiple line series in a single chart by adding dataSeries elements to data Array. Please take a look at the below code snippet for the same.

    data: [
      {        
    	type: "line",
    	dataPoints: [
    	  { x: 10, y: 21 },
    	  { x: 20, y: 25},
    	  { x: 30, y: 20 },
    	  { x: 40, y: 25 },
    	  { x: 50, y: 27 },
    	  { x: 60, y: 28 },
    	  { x: 70, y: 28 },
    	  { x: 80, y: 24 },
    	  { x: 90, y: 26}
    	]
      },
      {        
    	type: "line",
    	dataPoints: [
       	  { x: 10, y: 31 },
       	  { x: 20, y: 35},
       	  { x: 30, y: 30 },
       	  { x: 40, y: 35 },
       	  { x: 50, y: 35 },
       	  { x: 60, y: 38 },
       	  { x: 70, y: 38 },
       	  { x: 80, y: 34 },
       	  { x: 90, y: 44}
    	]
       },
       .
       .
       .
    ]

    Also, please take a look at this documentation page for more information on creating multi-series chart.

    Multi Series Line Chart

    —-
    Manoj Mohan
    Team CanvasJS

    in reply to: Regarding Multiples Y Axis Zoom #26264

    Deepak,

    It’s not possible to selectively zoom/pan based on a specific axis. However, this JSFiddle shows the nearest possible working solution using rangeChanging event.


    Manoj Mohan
    Team CanvasJS

    in reply to: Regarding Y Axis Zoom Limit/Restrict #26263

    Deepak,

    Sorry, this feature is not available as of now.

    —-
    Manoj Mohan
    Team CanvasJS

    in reply to: graph is not plotting in internet explorer #26259

    @shreekanthb28,

    Can you please check the browser console for any errors and also share JSFiddle reproducing the issue you are facing so that we can look into the code, understand the scenario better and help you out?

    —-
    Manoj Mohan
    Team CanvasJS

    in reply to: About Commercial version #26251

    Sorawit,

    Our sales team have reverted back to you over email with the replies to the above queries.

    —-
    Manoj Mohan
    Team CanvasJS

    in reply to: HTML tags #26229

    @inbar,

    HTML tags are not supported in indexLabels as of now.

    —-
    Manoj Mohan
    Team CanvasJS

Viewing 15 posts - 676 through 690 (of 796 total)