求救,如何生成柱状图,拆线图等统计图?
目前要做一个类似网上调查的项目,然后根据调查得到的数据进行分析,最后生成相关的曲线图表,还要支持打印...
没有做过,大家帮帮我,用什么做?或者给我提供些资料吧...
顶者有分..
[解决办法]
我觉得用RDLC报表做比较好一些
[解决办法]
www.wfsoft.com
[解决办法]
http://blog.csdn.net/luck0235/archive/2007/01/22/1490258.aspx
[解决办法]
http://www.yesky.com/20030324/1658705.shtml
[解决办法]
NetAdvantage 2006使用这个第三方控件
很简单
他有一百多种图形可以调用
[解决办法]
使用dotnetcharting.
[解决办法]
用第三方控件了
[解决办法]
office的owc
好用又听漂亮的
try!!
[解决办法]
dundas
前段时间用过
[解决办法]
mark
[解决办法]
www.wfsoft.com
[解决办法]
3楼的不错
[解决办法]
http://blog.csdn.net/nyzfl/archive/2007/03/06/1521898.aspx
[解决办法]
owc
[解决办法]
顶,OWC OR 水晶报表
[解决办法]
水晶报表
[解决办法]
http://www.wave12.com/web/home.asp
图表组件wsChart4.6(DLL版)
[解决办法]
try..ZedGraph..
WinForm下应用请参见:
http://www.codeproject.com/csharp/ZedGraph.asp
WebForm下应用请参见:
http://zedgraph.org/wiki/index.php?title=Use_a_MasterPane_in_a_web_page
http://zedgraph.org/wiki/index.php?title=Use_RenderMode.ImageTag_in_a_web_page
http://zedgraph.org/wiki/index.php?title=Use_RenderMode.RawImage_in_a_web_page
另外给你一个以前自己学的时候写的一个小例子:
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
private void Form1_Load(object sender, EventArgs e)
{
CreateGraph(this.zedGraphControl1);
SetSize();
}
private void CreateGraph(ZedGraphControl zgc)
{
MasterPane master = zgc.MasterPane;
master.PaneList.Clear();
master.Title.Text = "学生个体学习特点分析 ";
master.Title.IsVisible = true;
master.Fill = new Fill(Color.White, Color.MediumSlateBlue, 45.0F);
master.Margin.All = 10;
master.InnerPaneGap = 10;
master.Legend.Position = ZedGraph.LegendPos.TopCenter;
//添加学习策略整体比较图
GraphPane pane = new GraphPane();
pane.Title.Text = "**同学的学习策略整体比较图 ";
pane.XAxis.Title.Text = "学习策略 ";
pane.YAxis.Title.Text = "百分数 ";
pane.YAxis.MajorGrid.IsVisible = true;
pane.XAxis.Type = AxisType.Text;
pane.YAxis.Scale.Min = 0;
pane.YAxis.Scale.Max = 120;
string[] lables = new string[] { "预\n习\n策\n略 ", "听\n讲\n策\n略 ", "复\n习\n策\n略 ", "作\n业\n策\n略 ", "总\n结\n策\n略 ", "阅\n读\n策\n略 ", "时\n效\n策\n略 ", "记\n忆\n策\n略 ", "创\n新\n策\n略 " };
double[] scores = new double[] { 45.67, 56.89, 90.45, 48.29, 60.45, 45.67, 40.34, 87.65, 67.48 };
LineItem line = pane.AddCurve( "你的学习策略 ", null, scores, Color.Red, SymbolType.Square);
line.Symbol.Fill = new Fill(Color.Gray);
pane.XAxis.Scale.TextLabels = lables;
pane.Chart.Fill = new Fill(Color.White, Color.SteelBlue, 45.0f);
pane.Legend.Position = ZedGraph.LegendPos.TopCenter;
master.Add(pane);
//增加学习压力和自我调节图
pane = new GraphPane();
pane.Title.Text = "**同学的学习压力与自我调节图 ";
pane.XAxis.Title.Text = "百分数 ";
pane.XAxis.MajorGrid.IsVisible = true;
pane.XAxis.Scale.Min = 0;
pane.XAxis.Scale.Max = 100;
pane.YAxis.Title.IsVisible = false;
string[] ylables = new string[] { "自我调节 ", "学习压力 " };
double[] x = new double[] { 38, 73 };
BarItem bar = pane.AddBar( " ", x, null, Color.Red);
bar.Bar.Fill = new Fill(Color.White, Color.Red, 90.0F);
pane.YAxis.MajorTic.IsBetweenLabels = true;
pane.YAxis.Scale.TextLabels = ylables;
pane.YAxis.Type = AxisType.Text;
pane.BarSettings.Base = BarBase.Y;
pane.BarSettings.Type = BarType.Stack;
pane.Chart.Fill = new Fill(Color.White, Color.FromArgb(255, 255, 166), 45f);
//给柱形图加上标签
//设置lable与柱形图的间距
float offset =(float ) (pane.XAxis.Scale.Max - pane.XAxis.Scale.Min) * 0.02f;
ValueHandler valueHandler = new ValueHandler(pane, true);
int curveIndex=0;
foreach (CurveItem curve in pane.CurveList)
{
BarItem barItem = curve as BarItem;
if (bar != null)
{
IPointList points = curve.Points;
for (int i = 0; i < points.Count; i++)
{
double baseVal, lowVal, HighVal;
valueHandler.GetValues(curve, i, out baseVal, out lowVal,out HighVal);
float centerVal = (float)valueHandler.BarCenterValue(bar, bar.GetBarWidth(pane), i, baseVal, curveIndex);
string barLabelText = points[i].X .ToString( "0.00 ");
float position = (float)HighVal + offset;
TextObj label = new TextObj(barLabelText, position, centerVal);
label.Location.CoordinateFrame = CoordType.AxisXYScale;
label.FontSpec.Size = 12;
label.FontSpec.FontColor = Color.Black;
label.FontSpec.Angle = 0;
label.Location.AlignH = AlignH.Left;
label.Location.AlignV = AlignV.Center;
label.FontSpec.Border.IsVisible = false;
label.FontSpec.Fill.IsVisible = false;
pane.GraphObjList.Add(label);
}
}
curveIndex++;
}
master.Add(pane);
//设置不允许滚动
this.zedGraphControl1.IsEnableHZoom = false;
this.zedGraphControl1.IsEnableVZoom = false;
//显示节点的值
this.zedGraphControl1.IsShowPointValues = true;
this.zedGraphControl1.PointValueEvent += new ZedGraphControl.PointValueHandler(zedGraphControl1_PointValueEvent);
//设置layout
using (Graphics g = this.zedGraphControl1.CreateGraphics())
{
master.SetLayout(g, PaneLayout.SingleColumn);
master.AxisChange(g);
}
}
string zedGraphControl1_PointValueEvent(ZedGraphControl sender, GraphPane pane, CurveItem curve, int iPt)
{
//如果是Bar
if (curve.IsBar)
{
return pane.YAxis.Scale.TextLabels[iPt] + ": " + curve.Points[iPt].X.ToString() + "% ";
}
else if (curve.IsLine)
{
return pane.XAxis.Scale.TextLabels[iPt].Replace ( "\n ", " ") + ": " + curve.Points[iPt].Y.ToString() + "% ";
}
else
return " ";
}
private void Form1_Resize(object sender, EventArgs e)
{
SetSize();
}
private void SetSize()
{
this.zedGraphControl1.Location = new Point(10, 10);
this.zedGraphControl1.Size = new Size(ClientRectangle.Width - 20, ClientRectangle.Height - 20);
}
}
[解决办法]
1,ZedGraph
2,owc
3,自己画
[解决办法]
owc
[解决办法]
MARK
[解决办法]
ASP.NET2.0轻松搞定统计图表【月儿原创】
http://blog.csdn.net/21aspnet/archive/2007/03/27/1543320.aspx
[解决办法]
路过!
[解决办法]
给你来个全的
18个WebChart生成各种曲线/柱状图C#源码
http://www.51aspx.com/CV/WebChart/
下面有代码佩文
[解决办法]
学习来了
[解决办法]
我是用vml画的。感觉还是挺好用的。
http://www.microsystem.cn/vmlChart/