简体   繁体   English

使用Jquery Json将数据绑定到Asp.net HighCharts

[英]Binding Data to Asp.net HighCharts using Jquery Json

I have a asp.net chart which shows some attendance of month. 我有一个asp.net图表,其中显示了每月的出勤情况。

I have a dropdown which shows the month name. 我有一个下拉列表,显示月份名称。 The user will select the month from the dropdown and click on a button. 用户将从下拉菜单中选择月份,然后单击一个按钮。

On this button click, I want to call ActionResult mettod, which will fetch the data from a database of selected month and bind the data to chart(dotnet.highcharts). 单击此按钮后,我要调用ActionResult mettod,它将从选定月份的数据库中获取数据并将数据绑定到chart(dotnet.highcharts)。

I want to know if I can bind data to an asp.net chart with specific values. 我想知道是否可以将数据绑定到具有特定值的asp.net图表。 Can anyone please let me know how to do this? 谁能让我知道该怎么做?

Your method would probably return JsonResult in that case. 在这种情况下,您的方法可能会返回JsonResult。 Once you receive that json on the client side (through ajax request eg) you would submit it to Highcharts series property. 一旦在客户端(例如通过ajax请求)接收到该json,您就可以将其提交给Highcharts系列属性。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM