Jump to content
Sign in to follow this  

Cant figure out what's wrong with this expression

Recommended Posts


Help please? I want $check to be +/- 2 of $nCurrent

$check = ClipGet()
   $up = $nCurrent + 2
   $down = $nCurrent - 2
   if $check = >$down And <$up Then
Edited by Cormin

Share this post

Link to post
Share on other sites

oh, less than or equal to...:

$nCurrent = 10

For $i = 5 To 15

Func yourcheck()
    $check = ClipGet()
    If $check <= ($nCurrent+2) And $check >= ($nCurrent-2) Then
        ConsoleWrite("inside: " & $check & @CRLF)
        ConsoleWrite("outside: " & $check & @CRLF)


outside: 5
outside: 6
outside: 7
inside: 8
inside: 9
inside: 10
inside: 11
inside: 12
outside: 13
outside: 14
outside: 15

Edited by jdelaney

IEbyXPATH-Grab IE DOM objects by XPATH IEscriptRecord-Makings of an IE script recorder ExcelFromXML-Create Excel docs without excel installed GetAllWindowControls-Output all control data on a given window.

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  


Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.