Jump to content

MouseGetPos() Array Problem


buzz44
 Share

Recommended Posts

hey eveyone...

i have this statement

If $pos[0] = $pos1[0] then
      $i = $i
   else
      $i = $i + 1
EndIf
it works's fine

but i want to get the Y coord value as well and when i try

If $Pos[0] = $Pos1[0] & $Pos[1] = $Pos[1] then
   $i = $i
else then
   $i= $i + 1
 endif

the value u of $i goes up constantly... i have a tool tip that shows me the value of $i and it just goes up and up when i run the 2nd code.

wats wrong?

thx

Edited by burrup

qq

Link to comment
Share on other sites

  • Developers

If $Pos[0] = $Pos1[0] & $Pos[1] = $Pos[1] then
   $i = $i
else then
   $i= $i + 1
 endif

wats wrong?

thx

<{POST_SNAPBACK}>

& is used to concatenate 2 strings. replace it with AND :

If $Pos[0] = $Pos1[0] And $Pos[1] = $Pos[1] then

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

If $Pos[0]= $Pos1[0] And $Pos[1] = $Pos[1] then

Aren't you setting $pos[1] equal to itself? Shouldn't it be

If $Pos[0] = $Pos1[0] And $Pos[1] = $Pos1[1] then

Edited by Blue_Drache

Lofting the cyberwinds on teknoleather wings, I am...The Blue Drache

Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...