由于以前很少接触曲线图不知道如何下手,想实现共用一个横坐标多个纵坐标曲线图,如图:
ASP.NET曲线
ASP.NET曲线
解决方案 »
- 高手进,在线求助 !!!!转化问题 在线等
- vs2005中如何添加ocx组件??
- asp.net上传到空间时抛出System.Data.OleDb.OleDbException: 未指定的错误,麻烦各位帮我看看
- 一个难题,请高手指点!!在线等…
- vs.net2003编辑器里,.aspx文件在设计模式加点东东后,再到html模式,发现代码格式自动变了,变得没有条理性了,俺喜欢自己组织代码,各
- 求问:b/s中,如何实现一段自定义格式的动画声音播放??
- 各位兄台,很着急的一个问题(关于用户控件)
- 请问在select语句中如何实现同时含有两个关键字的搜索?急!!!在线等待!
- 简单的treeview问题
- 高分请教:DATAGRID中内置DROPDOWNLIST(数据绑定)时报错。(附代码)
- overflow:hidden的问题
- MVC3 下的一个View 页面用html标签属性的问题
public Bitmap MergerImg(Bitmap[] maps, System.Web.UI.WebControls.RepeatDirection RepeatDirection)
{
if (maps.Length == 0)
throw new Exception("图片数不能够为0"); int _width = 0;
int _height = 0;
for (int i = 0; i < maps.Length; i++)
{
if (RepeatDirection == System.Web.UI.WebControls.RepeatDirection.Horizontal)
{
_width += maps[i].Width;
if (maps[i].Height > _height)
{
_height = maps[i].Height;
}
}
else
{
_height += maps[i].Height;
if (maps[i].Width > _width)
{
_width = maps[i].Width;
}
}
}
//创建要显示的图片对象,根据参数的个数设置宽度
Bitmap backgroudImg = new Bitmap(_width, _height);
Graphics g = Graphics.FromImage(backgroudImg); //清除画布,背景设置为白色
int len = maps.Length;
g.Clear(System.Drawing.Color.White);
int x = 0;
for (int j = 0; j < len; j++)
{
if (RepeatDirection == System.Web.UI.WebControls.RepeatDirection.Horizontal)
{
g.DrawImage(maps[j], x, 0, maps[j].Width, maps[j].Height);
x = x + maps[j].Width;
}
else
{
g.DrawImage(maps[j], 0, x, maps[j].Width, maps[j].Height);
x = x + maps[j].Height;
}
}
g.Dispose();
return backgroudImg;
}