hey me again ...
I got this code... All mine
VB Code:
Public Function TestColor(Colortest As Long) As String Dim X As Long, Y As Long, test As Long, wndrect As RECT GetWindowRect selWnd, wndrect test = GetDC(selWnd) TestColor = false For Y = 0 To (wndrect.Bottom - wndrect.Top) For X = 0 To (wndrect.Right - wndrect.Left) If GetPixel(test, X, Y) = Colortest Then TestColor = true Exit Function Exit Function End If Next X Next Y End Function
but when i type in
if testcolor(255)=true then msgbox "Found it"
if doesnt find it... but if i put in false it does find it....
I know there is a color 255 on my screen but it all screws up....
ive tried reversin the true and false statements but it still works in reverse....
any help?
