New to Telerik UI for ASP.NET CoreStart a free 30-day trial

Events

The StockChart exposes a variety of events that you can handle and further customize the behavior of the UI component.

For a complete example on basic Chart events, refer to the demo on using the events of the Chart.

Handling by Handler Name

The following example demonstrates how to subscribe to events by a handler name.

Razor
    @(Html.Kendo().StockChart<StockDataPoint>()
         .Name("stockChart")
         .Events((Action<Kendo.Mvc.UI.Fluent.StockChartEventBuilder>)(e => e.Render("onDataBound")))
    )

Handling by Template Delegate

The following example demonstrates how to subscribe to events by a template delegate.

Razor
    @(Html.Kendo().StockChart<StockDataPoint>()
         .Name("stockChart")
         .Events((Action<Kendo.Mvc.UI.Fluent.StockChartEventBuilder>)(e => e.Render(@<text>
                function() {
                    // Handle the render event inline.
                }
           </text>))
        )
    )

Next Steps

See Also