This is a migrated thread and some comments may be shown as answers.

[Solved] StackOverflowException

3 Answers 34 Views
Chart
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Marcos
Top achievements
Rank 1
Marcos asked on 29 Jul 2011, 09:35 PM
I was trying to test the chart component, but I got a StackOverflowException. The problem only occurs with Line series.
Code to reproduce:

        var a= new List<int>();
        a.Add(1);
        a.Add(2);
        a.Add(3);
        a.Add(4);
 
        var b= new List<int>();
        b.Add(2);
        b.Add(3);
        b.Add(4);
        b.Add(5);
 
 
        var cat= new List<string>();
        cat.Add("1ª");
        cat.Add("2ª");
        cat.Add("3ª");
        cat.Add("4ª");
 
 
        Html.Telerik().Chart()
            .Name("chart")
            .Series(series =>
            {
                series.Line(a)
                    .Name("A");
                series.Line(b)
                    .Name("B");
 
            })
            .CategoryAxis(category =>
            {
                category.Categories(cat);
            })
            .Legend(legend =>
            {
                legend.Position(ChartLegendPosition.Bottom);
            })
            .HtmlAttributes(new { style = "width: 600px; height: 400px;" }).Render();

3 Answers, 1 is accepted

Sort by
0
T. Tsonev
Telerik team
answered on 01 Aug 2011, 08:40 AM
Hello Marcos,

This is a known issue in the official Q2 release. Please download an updated build from here.

I hope this helps.

Regards,
Tsvetomir Tsonev
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items

0
Marcos
Top achievements
Rank 1
answered on 01 Aug 2011, 03:03 PM
Hi,

Updated to the suggested version... Now I'm getting JS errors.
Debug info below. Let me know if I can help with something more.


On Firefox (provided by Firebug):
bq[X] is undefined
U()teleri....min.js (linha 1)
U()teleri....min.js (linha 1)
U()teleri....min.js (linha 1)
U(bq=div#chart.t-widget)teleri....min.js (linha 1)
U()teleri....min.js (linha 1)
U()teleri....min.js (linha 1)
create()teleri....min.js (linha 1)
d(a=[div#chart.t-widget], c=function(), e=undefined)jquery....min.js (linha 16)
d(a=function(), b=undefined)jquery....min.js (linha 16)
(?)()Test (linha 173)
d(d=Document Test, f=[function()])jquery....min.js (linha 16)
d(a=undefined)jquery....min.js (linha 16)
d()jquery....min.js (linha 16)

On Internet Explorer 9:
SCRIPT5007: Unable to set value of the property '_childIndex': object is null or undefined
telerik.chart.min.js, line 1 character 31503

Google Chrome:
  1. Uncaught TypeError: Cannot set property '_childIndex' of undefined
    1. C.bc.extend.sortChildrentelerik.chart.min.js:1
    2. C.bc.extend.renderContenttelerik.chart.min.js:1
    3. anonymous:2
    4. C.bc.extend.rendertelerik.chart.min.js:1
    5. M.L.extend.renderTotelerik.chart.min.js:1
    6. bh.N.extend._redrawtelerik.chart.min.js:1
    7. bh.N.extend._refreshtelerik.chart.min.js:1
    8. bh.N.extend.inittelerik.chart.min.js:1
    9. aN.fn.tChart.z.create.inittelerik.chart.min.js:1
    10. aa.m.telerik.createtelerik.common.min.js:1
    11. d.d.extend.eachjquery-1.5.2.min.js:16
    12. aa.m.telerik.createtelerik.common.min.js:1
    13. (anonymous function)Test:173
    14. d.extend._Deferred.f.resolveWithjquery-1.5.2.min.js:16
    15. d.d.extend.readyjquery-1.5.2.min.js:16
    16. d.c.addEventListener.yjquery-1.5.2.min.js:16


0
T. Tsonev
Telerik team
answered on 02 Aug 2011, 03:34 PM
Hello Marcos,

I've tested the original code you've sent with the updated version and everything seems to work correctly. See the attached project.

Regards,
Tsvetomir Tsonev
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items

Tags
Chart
Asked by
Marcos
Top achievements
Rank 1
Answers by
T. Tsonev
Telerik team
Marcos
Top achievements
Rank 1
Share this question
or