locked
hey please help me? RRS feed

  • Question

  • NOw I have inserted a picturebox and now I have to get the color value of a pixel of the image which I load to it
    please help me!
    Tuesday, August 18, 2009 6:34 AM

Answers

  • convert the color

    Dim ColorValue as integer = FoundColor.ToARGB()

    Asgar
    • Marked as answer by RI26 Tuesday, August 18, 2009 12:28 PM
    Tuesday, August 18, 2009 11:41 AM

All replies

  • Hi,

    first, please do your posting headline a little bit more exactly. If you would search for help or help me you will find a lot of posts. Beeing more clearly of what you want will get yourproblems solved faster.

    For your problem use the GetPixel(x,y) function of the Bitmap Class which will return a System.Drawing.Color.

    Like:

    Dim FoundColor As System.Drawing.Color
    FoundColor = YourBitmap.GetPixel(x, y)
    where YourBitmap is a Bitmap out of your Image.



    If you have got questions about this, just ask.
    Mark the thread as answered if the answer helps you. This helps others who have the same problem !
    • Proposed as answer by FthrJACK Tuesday, August 18, 2009 7:20 AM
    Tuesday, August 18, 2009 6:43 AM
  • here is a link to the Bitmap.GetPixel page on MSDN

    http://msdn.microsoft.com/en-us/library/system.drawing.bitmap.getpixel.aspx
    Tuesday, August 18, 2009 6:54 AM
  • thnx dud but what i want is not that i want the value in integer or long variable type
    thnx again
    Tuesday, August 18, 2009 11:31 AM
  • thnx
    Tuesday, August 18, 2009 11:32 AM
  • convert the color

    Dim ColorValue as integer = FoundColor.ToARGB()

    Asgar
    • Marked as answer by RI26 Tuesday, August 18, 2009 12:28 PM
    Tuesday, August 18, 2009 11:41 AM