Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Drawing line and customizing the color
Message
From
01/01/2005 14:21:07
 
 
To
31/12/2004 18:37:37
General information
Forum:
ASP.NET
Category:
Pictures and Image processing
Miscellaneous
Thread ID:
00973596
Message ID:
00973639
Views:
21
>I am using this to draw a line:
>
>
>    ' Draw the squares for the status bar
>    Protected Overrides Sub OnPaint(ByVal e As System.Windows.Forms.PaintEventArgs)
>        Dim loGraphic As Graphics = e.Graphics
>        Dim loPen As Pen = New Pen(Color.Blue, 1)
>        loGraphic.DrawLine(loPen, 0, 623, 200, 623)
>    End Sub
>
>
>How can I change the Pen line to have a custom color such as 172,168,153?

I add to use this syntax instead:
        Dim loPen As Pen = New Pen(Color.FromArgb(172, 168, 153), 1)
Michel Fournier
Level Extreme Inc.
Designer, architect, owner of the Level Extreme Platform
Subscribe to the site at https://www.levelextreme.com/Home/DataEntry?Activator=55&NoStore=303
Subscription benefits https://www.levelextreme.com/Home/ViewPage?Activator=7&ID=52
Previous
Reply
Map
View

Click here to load this message in the networking platform