Programming Journal C#, Java, SQL and to a lesser extent HTML, CSS, XML, and regex. I made this so other programmers could benefit from my experience.

Tuesday, December 23, 2008

Add Google Charts with .NET

Add Google Charts with .NET.
Go to: http://code.google.com/p/googlechartsharp/
Download DLL.
Save and Unzip to location.

From your project, add reference.
Select DLL.
Copy source code from below:

// using GoogleChartSharp;

int[] data = new int[] { 40, 30, 20, 10, 0 };

// Specify chart width and height in pixels
LineChart chart = new LineChart(150, 150);

// SetData will accept int[] and float[] for single data sets
chart.SetData(data);

string imageUrl = chart.GetUrl();
Image1.ImageUrl = imageUrl;
Run. Enjoy. Modify. Visit these sites for more:
http://groups.google.com/group/google-chart-api/web/useful-links-to-api-libraries

References:
http://code.google.com/p/googlechartsharp/
http://code.google.com/p/googlechartsharp/wiki/UsageExamples

1 comment:

Anonymous said...

Can anyone recommend the best IT automation system for a small IT service company like mine? Does anyone use Kaseya.com or GFI.com? How do they compare to these guys I found recently: N-able N-central software deployment
? What is your best take in cost vs performance among those three? I need a good advice please... Thanks in advance!