0

I wanna make a program that will be able to get the color of a specific button on a different programs. so i need to get the pixel color of that button.*i don't have access on the files of the second application, so i cant make them communicate.

Every google search gave me nothing but endless hours of reading. Any ideas?

zomit ara
  • 13
  • 1
  • https://stackoverflow.com/questions/1483928/how-to-read-the-color-of-a-screen-pixel – Iłya Bursov Oct 05 '18 at 00:02
  • 2
    Possible duplicate of [How to read the Color of a Screen Pixel](https://stackoverflow.com/questions/1483928/how-to-read-the-color-of-a-screen-pixel) – JleruOHeP Oct 05 '18 at 00:05

1 Answers1

1
  1. Capture Current Screen and hold image in 'Bitmap'
  2. Get 'Current Mouse Location'
  3. Find 'Current Mouse Location' Pixel on 'Bitmap'
  4. Get Color on Pixel with this code

    'Bitmap'.GetPixel( 'MouseLocation'.X, 'MouseLocation'.Y);

Arphile
  • 841
  • 4
  • 17
  • 1
    Thank you for your answer Alphile! What i actually try to do is to automate the script without user input like mouse. – zomit ara Oct 05 '18 at 00:32
  • you can change 'mouse' as others. even you can check 'box area' with rectangle and so on. – Arphile Oct 05 '18 at 00:40