Click here to Skip to main content
15,891,473 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
HI,

I am new in MS Chart but i want to a chart with database. I found many article on net but my requirement is different.
In My database I have table "UserTAT" and its Column Name is "INTAT" , "OUTTAT" , "PASSTAT"
and these column contain only integer value. like this.

Table Name: - UserTAT

Column Name: INTAT OUTTAT PASSTAT
Row Value : 2 4 10
4 6 20

Now i want to column name in x-aisx and column value in y-asix. Please Help me to solve this problem. Please check image link to see chart type i want. Help.
http://rashtriyasakshartamission.com/chartsample.png

Thanks
Posted
Updated 13-Jan-13 9:58am
v3
Comments
NeerajBhagat09 13-Jan-13 16:18pm    
Do you want the graph for a single row?
Ram Kumar(Webunitech) 14-Jan-13 11:24am    
yes sir
jkirkerx 13-Jan-13 19:22pm    
Are you doing this in code behind, pure code, or are you using the control object in design view?

Are you using 3.5 or 4.0?
Ram Kumar(Webunitech) 14-Jan-13 11:23am    
I am using 4.0

I assume your using the design view to build your chart

First, you need to know that there is the chart and there are series.

You place the chart object on your webform first, and size it, and then paint it, using the properties F4. When you have designed your chart, then you can build series, which are the data points. So start with adding manual data points first to learn how to build a series.

When you chart looks good, now you can attach your data to the chart.

So now you go to the code behind page, and make a reference to the chart, in which you create a new series, and then add the series to the chart.

The link below shows how to write code for series, and attach it to the chart.


http://www.mschartcontrol.blogspot.com/[^]
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900