Search code examples
c#jqueryasp.netflot

Making charts in ASP.NET with Flot and get the values from code-behind file


I'm working on a project were I have input from the user from the ASP.NET page. This input is then being processed into data and with this data I can create charts, this works with the Microsoft standard Charting library's.

But now I want to make the same chart but with Flot. I can make a Flot chart but this data is hard-coded in the .ASPX page. This is with jQuery.

What I'm trying to do is let the code-behind file fill in the chart. I know I need to use JSON (which I'm not acquainted with), but I don't know how.


Solution

  • I think what you want to do is to use AJAX do load data dynamically from a server.

    Here is an example to do as much.

    http://people.iola.dk/olau/flot/examples/ajax.html

    Let me know if this is not that for which you are looking.