绘制简单的线图 [英] Draw simple line graph

查看:97
本文介绍了绘制简单的线图的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

嗨..我是C#编程的新手..我从.txt文件中读取了一组数据,并且数据已经存储在数组中..现在,我想使用Microsoft Visual C#2005绘制简单的折线图,但是当我计划在Form ..上绘制此版本时,该工具箱内的图表无法控制.您是否知道如何使用其他类的数据绘制简单的折线图? .=)

Hi..I am new to C# programming..i had a set data read from .txt file and the data were already store inside an array..now i would like to draw a simple line graph using microsoft visual c# 2005, but there is no control of chart inside the toolbox for this version when i plan to draw it on Form..do u have any idea how to plot a simple line graph using the data from the other class..?thanks in advance..=)

推荐答案

看看
Have a look at ASP.NET and Windows Forms Chart Controls for .NET Framework 3.5 SP1[^].

It''s a free download.

MSChart will not work with older versions of .Net, the download does after all specify .net 3.5 so you need to upgrade Visual studio to version 2008. The component is included with Visual Studio 2010.

Best regards
Espen Harlinn


您的大问题是使用软件的很旧的版本:VS2005已有7年的历史了,并且已有三个版本. MS Chart控件(我认为)是在VS2008中引入的.NET V3.5引入的.

在这里查看:
.NET的灵活图表库 [ ^ ]
它包括VS2005支持的.NET 1.1版本,但我强烈建议您需要更新开发环境! MS确实提供Visual Studio的免费版本-它们称为Express版本,可以直接从其网站上获得.
Your big problem is using a very old version of the software: VS2005 is 7 years and three versions old. The MS Chart control was (I think) introduced at .NET V3.5, which came in at VS2008.

Have a look here: A flexible charting library for .NET[^]
It includes a version for .NET 1.1 which VS2005 supports, but I would strongly suggest that you need to update your development environment! MS does do free versions of Visual Studio - they are called the Express versions and are available from thier web site directly.


我希望下面的代码可以为您提供帮助

I hope below code can help you

SparklineGroup sparklineGroup
= sheet.SparklineGroups.AddGroup(SparklineType.Line);
SparklineCollection sparklines = sparklineGroup.Add();
sparklines.Add(sheet["B2:E2"], sheet["F2"]);
sparklines.Add(sheet["B3:E3"], sheet["F3"]);
sparklines.Add(sheet["B4:E4"], sheet["F4"]);
sparklines.Add(sheet["B5:E5"], sheet["F5"]);



如果您仍然不清楚,请访问整篇文章
http://everlasting129.weebly.com/1/post/2012/01/how-to-insert-sparkline-chart-in-excel-with-c-vbnet.html [



if you still not clear about it,please visit the whole article
http://everlasting129.weebly.com/1/post/2012/01/how-to-insert-sparkline-chart-in-excel-with-c-vbnet.html[^]


这篇关于绘制简单的线图的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆