How can I get Linear gauge's SVG?

7 posts, 0 answers
  1. Paula
    Paula avatar
    4 posts
    Member since:
    Jun 2012

    Posted 01 Jun 2012 Link to this post

    Hi,

    I try to get SVG of Linear Gauge but I can't do it, I mean, I have two exceptions and I don't know what is that. Can you help me? 

    it's occurs in this part:
    var gauge = $("#gauge").data("kendoLinearGauge");
         gauge.svg();  

    Uncaught ReferenceError: Chart is not defined  
    Uncaught TypeError: Cannot read property '_animation' of undefined  

    thanks,

    Paula Castellanos
  2. Hristo Germanov
    Admin
    Hristo Germanov avatar
    703 posts

    Posted 05 Jun 2012 Link to this post

    Hello Paula,

    Can you give me your configuration of the LinearGauge, because I can't reproduce the issue.

    All the best,
    Hristo Germanov
    the Telerik team
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  3. Kendo UI is VS 2017 Ready
  4. Paula
    Paula avatar
    4 posts
    Member since:
    Jun 2012

    Posted 05 Jun 2012 Link to this post

    hi, 

    Well, the linear gauge's configuration is 

     function createGauges() {
                var theme = $(document).data("kendoSkin") || "default",
                            value = $("#gauge-value").val();


                $("#gauge").kendoLinearGauge({
                    theme: theme,


                    pointer: {
                        value: 28,
                        shape: "arrow"
                    },
                    scale: {
                        majorUnit: 20,
                        minorUnit: 20,
                        majorTicks: {
                            color: "#0000FF",
                            size: 10
                        },
                        min: -40,
                        max: 60, 
                        vertical: true,
                        ranges: [
                                    {
                                        from: -40,
                                        to: -20,
                                        color: "#2798df"
                                    }, {
                                        from: 25,
                                        to: 60,
                                        color: "#ffc700"
                                    }, {
                                        from: 30,
                                        to: 32,
                                        color: "#c20000"
                                    },
    {
       from: -20,
       to: 0,
       color: "#cFFFF22"
           }
                                ]
                    }
                });
                setInterval("updateValue()", 5000);            
            }
      //in this function I try to get SVG but I can't do it
            function svg() {
                var gauge = $("#gauge").data("kendoLinearGauge");
               var text = gauge.svg();
               alert(text);
            }

    //Update the graphics' value
            function updateValue() {
                $("#gauge").data("kendoLinearGauge").value(Math.floor((Math.random() * 40) + 1));
       svg();
            }
            $(document).ready(function () {
                createGauges();
                var gauge = $("#gauge").data("kendoLinearGauge");
                gauge.mirror = true;
                $(document).bind("kendo:skinChange", function (e) {
                    createGauges();
                });
            });
    }

    I don't what happen, I mean, if you look the configuration is very easy and basic.

    Thanks.

  5. Hristo Germanov
    Admin
    Hristo Germanov avatar
    703 posts

    Posted 05 Jun 2012 Link to this post

    Hello Paula,

    The problem is fixed in the Q1 2012 SP1 of Kendo UI.

    Kind regards,
    Hristo Germanov
    the Telerik team
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  6. Paula
    Paula avatar
    4 posts
    Member since:
    Jun 2012

    Posted 05 Jun 2012 Link to this post

    Hi,
    But I have version 2012.1 322, How can I get the version 2012.1.515?, I mean, is it necessary  new license?
    Thanks.  
     

  7. Hristo Germanov
    Admin
    Hristo Germanov avatar
    703 posts

    Posted 06 Jun 2012 Link to this post

    Hi Paula,

    The service pack of the Q1 2012 (version 2012.1.515) is available only for customers. Users with a trial or GPL version of Kendo UI should wait for the next official release of Kendo UI (scheduled for July 2012). If you don't want to wait until the official release you need to update your license to Kendo UI Complete or Kendo UI DataViz.

    Kind regards,
    Hristo Germanov
    the Telerik team
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  8. Paula
    Paula avatar
    4 posts
    Member since:
    Jun 2012

    Posted 07 Jun 2012 Link to this post

    Hi,

    Thanks, now it's perfect. :D
Back to Top
Kendo UI is VS 2017 Ready