Krzysztof Mossakowski
.NET Programming
2007 - Tasks
ASP.NET
Chart Control
User control (inherits System.Web.UI.UserControl)
pie chart
random "pie" parts colors (white background)
dynamically created images (use HTTP Handler, saving images do a disk is not allowed)
description of the data located on each "pie" fragment
images are provided to a browser as a PNG image files
author could assume that the sum of all the data is 100.0%
Obligatory properties
DataSource - both DataSet object of DataTable object must be allowed
DataMember - source table name in the case when DataSource is a DataSet type
DataTextField - name of the column with data description
DataValueField - name of the column with data
Size - size of the chart image
Example control usage - ASP.NET 2.0 Web Site
2 controls on the default web form
one using DataSet as a DataSource - data loaded from
this file
another one uses dynamically created DataTable data source
Hints:
UserControl.Cache
Image.Save(Stream, ImageFormat)
Page.MapPath()
Approximate points:
user control
DataSet data source: 1.0
DataTable data source: 1.0
pie chart: 2.5
data description on the image: 1.5
HTTP Handler: 2.0
example application: 2.0
Links for uploading:
Solutions
Corrections