求助:如何用vba代码在主图画一条y=kx+b直线,比方是y=3x+10的直线
Gird 对象
DrawLine 方法
在指定位置绘制直线。
DrawLine(StartX, StartY, EndX, EndY, [Color], [Width], [Style])
StartX,StartY 起始点坐标。
EndX,EndY 结束点坐标
Color 可选参数,颜色值。
Width 可选参数,默认为1。
Style 可选参数,线条风格。0实线 1虚线 2点线 3虚线和点线交替,1-3风格只有Width为1时才有效。
参考
http://www.weistock.com/bbs/dispbbs.asp?BoardID=5&ID=30904&skin=0