0

Is there any way to Add multiple vertical axis dynamically to Line chart in Kendo ui? right now am using the following snippet for 2 vertical axis in kendo ui Line chart

valueAxes: [{
        name: "test",
        color:"#07eeff",
              labels: {
                format: "{0}pu"
        }        
    }, {
        name: "test1",
        color:"#07eeff",
      labels: {
                format: "{0}C"
        }
    }
            ],

I am using the following link for reference: http://docs.telerik.com/kendo-ui/getting-started/dataviz/chart/overview#multiple-value-axes

If there is any way to Add multiple vertical axis dynamically(through JSON Data) to Line chart in Kendo-ui then please let me know.

sonyisda1
  • 422
  • 1
  • 8
  • 21
  • why this was tagged with `jQuery`? – Murali Murugesan Jun 04 '14 at 11:34
  • Please check the below link it will help you. Let me know if you face any issue. http://jayeshgoyani.blogspot.in/2013/05/how-to-add-multiple-lines-series.html – Jayesh Goyani Jun 04 '14 at 12:20
  • @JayeshGoyani:Thanks for your reply.your link is for adding multiple line series dynamically but i want multiple vertical Axis(Y-Axis) not the line series. – user3706745 Jun 04 '14 at 13:18
  • @user3706745, Please check below demo in my (answer) post. You may get idea how to add series and valueaxies in kendo chart. Please provide your code snippet is if you have any concern. – Jayesh Goyani Jun 04 '14 at 13:31

1 Answers1

0

Please try with the below code snippet and DEMO.

$.each(valueAxes, function (index, valueAxes) {
                            if (valueAxes.name == nodeText.trim()) {
                                checkedAxes.push(valueAxes);
                                checkedAxes.visible = true;
                            }
                        });

                        $.each(series, function (index, series) {
                            if (series.name == nodeText.trim()) {
                                checkedSeries.push(series);
                            }
                        });
                    });   

Please check below demo for more clarification.

Demo

Jayesh Goyani
  • 11,008
  • 11
  • 30
  • 50