mattscotney
Member
- Joined
- Jul 9, 2003
- Messages
- 13
How do I create an color dropper tool?
I need the code to get the color of the pixel at the position of the mouse.
This is what I have done so far, I can get the pixel color of a bitmap, but how do I get the color of the screen at any given pixel?
Thanks in advance
I need the code to get the color of the pixel at the position of the mouse.
This is what I have done so far, I can get the pixel color of a bitmap, but how do I get the color of the screen at any given pixel?
Code:
Dim bmp = New Bitmap("bg.gif")
Dim z As Color
z = bmp.GetPixel(50, 50)
MsgBox(z.ToString)
Label4.BackColor = z
Thanks in advance
Last edited by a moderator: