kendo chart call out message

非 Y 不嫁゛ 提交于 2019-12-02 06:42:32

问题


I have a kendo line chart which will bind the data from Model as below. Now i would like to show at particular point a call out message saying degradation start at this point dynamically. Can some one help me on this how to acheive this.

<div style="overflow:scroll;width:100%">
            @if (@Model != null && @Model.XYAxisData != null)
            {
                @(Html.Kendo().Chart()
        .Name("Predictionchart")
        .Transitions(false)
        .RenderAs(RenderingMode.Canvas)
                    //.Title(Model.YString + " Vs " + Model.XString + " Relationship")
        .Legend(legend => legend
            .Position(ChartLegendPosition.Right).Visible(true)
        )
       .SeriesDefaults(seriesDefaults =>
            seriesDefaults.Line().Style(ChartLineStyle.Smooth)

            )

        .Series(series =>
        {

            series.ScatterLine(Model.XYAxisData).Fields("xValue", "yValue");
            series.ScatterLine(Model.XYPredictedData).Fields("xValue", "yValue");

        })
        .ChartArea(x => x.Width(1000).Height(400))
        .XAxis(x => x
            .Numeric()
        .Title(title => title.Text(Model.PredictXString))
            .Crosshair(crosshair => crosshair
                .Visible(true)
                .Tooltip(tooltip => tooltip
                    .Visible(true)
                //.Format("{0:n1}")
                )
             )
                    //.Max(35)
        )
        .YAxis(y => y
            .Numeric()
            .Title(title => title.Text(""))
            .AxisCrossingValue(-5)
            .Crosshair(crosshair => crosshair
                .Visible(true)
                .Tooltip(tooltip => tooltip
                    .Visible(true)
                //.Format("{0:n1}")
                )
            )
                    //.Min(-5)
                    //.Max(25)
        )
                )
            }
        </div>

来源:https://stackoverflow.com/questions/34177391/kendo-chart-call-out-message

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!