查一下帮助,定义一个Graphics对象,用GDI+
解决方案 »
- VS2010的脱机MSDN Library在哪里
- 求解:用户 'sasa' 登录失败。该用户与可信 SQL Server 连接无关联
- 请问这样有这样的两张表, 怎样建立主从关系呢? 内详,先谢谢大家
- C# 里面内嵌一个第三方程序
- 【初学者求教】Timer里面做的事能放在另个线程中么?
- 探讨listbox控件 解决者 分值全给!!直接具体写出来 高分,高分!!
- 高手进,可能是清除内存的问题
- 并发操作的问题
- 请教 DataSet.Merge 方法 (DataRow[])
- 『新手求助』C#界面问题:在主FORM中要最大化打开3个FORM都是。多谢
- ASP.Net中调用COM组件的发布问题
- 请问怎样给DataGrid添加一个空行?
{
System.Drawing.Pen myPen =new Pen(Color.Black,1);
myPen.Width= linewidth;
//e.Graphics.Clear(this.BackColor);
switch (lineStyle)
{
case LineStyleMode.InSide :
switch (lineType)
{
case LineTypeMode.VLine:
myPen.Color=Color.Gray;
e.Graphics.DrawLine(myPen,0,2,this.Width,2);
myPen.Color=Color.White;
e.Graphics.DrawLine(myPen,0,3,this.Width,3);
break;
case LineTypeMode.HLine:
myPen.Color=Color.Gray;
e.Graphics.DrawLine(myPen,2,0,2,this.Height);
myPen.Color=Color.White;
e.Graphics.DrawLine(myPen,3,0,3,this.Height);
break;
default:
break;
}
break;
case LineStyleMode.OutSide :
switch (lineType)
{
case LineTypeMode.VLine:
myPen.Color=Color.White;
e.Graphics.DrawLine(myPen,0,2,this.Width,2);
myPen.Color=Color.Gray;
e.Graphics.DrawLine(myPen,0,3,this.Width,3);
break;
case LineTypeMode.HLine:
myPen.Color=Color.White;
e.Graphics.DrawLine(myPen,2,0,2,this.Height);
myPen.Color=Color.Gray;
e.Graphics.DrawLine(myPen,3,0,3,this.Height);
break;
default:
break;
}
break;
}
}
这个方法怎麽才能运行啊??