weixin_43756260 2019-05-05 09:29 采纳率: 100%
浏览 488
已采纳

VB里DrawLine指令里如何调用非标准色?又如何调用已经定义的颜色函数?

非标准色:
RGB(255, 13, 0)
颜色函数:
ReDim color(10)
color(0) = RGB(255, 13, 0)
color(1) = RGB(255, 77, 0)
color(2) = RGB(255, 176, 0)
color(3) = RGB(247, 248, 0)
color(4) = RGB(176, 255, 0)
color(5) = RGB(75, 255, 0)
color(6) = RGB(0, 255, 176)
color(7) = RGB(0, 248, 247)
color(8) = RGB(0, 176, 255)
color(9) = RGB(0, 75, 255)

  • 写回答

1条回答 默认 最新

  • threenewbee 2019-05-05 09:43
    关注

    Dim myPen As Pen = New Pen(new Color(255, 13, 0), 2)
    g.DrawEllipse(myPen, 30, 30, 90, 90) '在坐标为30,30 ~90,90 的范围内画一个红圆

    画线用的brush也一样,换成
    dim mysbrush1 as SolidBrush = new SolidBrush(new Color(xxx,xxx,xxx))

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?