Skip to main content

Dynamically create Bar Chart using Chart.js in Asp.net

This article explains about Bar Chart. We are going to create a simple Bar Chart using char.js library in jQuery. Bar Chart can be used to show data or compare multiple data sets.

Chart.js: A Simple chart library for developers developed by Nick Downie. It uses HTML5 canvas element and supports all the browsers. 

Code Snippet

Code Behind


Finally, we are done with coding. You can bind a real dataset from the code behind and see the output
Happy Coding :)

Comments

black samba said…
i have tried this code. but I don't know why it won't run and the chart won't show up. what i did is just copy the code and paste into new visual studio 2015 solution web form
Unknown said…
thanks this peace of code really help me out, ask a little this from you need a comma separated values on Y axis and tool tip kindly help