Jump to content

If function - (Locked)


CrazyMob
 Share

Recommended Posts


Func Reconnect()
   Do
      Sleep(50)
Until PixelGetColor (1083, 702) = 0x00EB39
   If PixelGetColor (1083, 702) = 0x00EB39 Then
      Sleep(60000)
       If PixelGetColor (1083, 702) = 0x00EB39 Then
Sleep(50)
     Relogin()

 

 

i have a function in my script and i want that it work only when  If PixelGetColor (1083, 702) = 0x00EB39 Then

and if the pixelgetcolor is not match i want it to ignore it whats wrong here please help ))

Link to comment
Share on other sites

Welcome to Autoit and the forum!

Can you please tell us which application you try to automate?
Using pixel coordinates is very unreliable as it depends on screen resolution, window position etc.
Most of the time there are more reliable ways to do what you want to do.

My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2022-02-19 - Version 1.6.1.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download
Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki
PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki
Task Scheduler (NEW 2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki

Standard UDFs:
Excel - Example Scripts - Wiki
Word - Wiki

Tutorials:
ADO - Wiki
WebDriver - Wiki

 

Link to comment
Share on other sites

for example ?
i play internet game on chrome and i find out the pixel cordinates its good enough just dont get why its not find the specific pixelcolour and still keep work on the next command i want that this func just check allways for this pixelgetcolour and if its there it will do the rest of actions

Link to comment
Share on other sites

  • Moderators

Welcome to the AutoIt forum.

Unfortunately you appear to have missed the Forum rules on your way in. Please read them now - particularly the bit about not discussing game automation - and then you will understand why you will get no help and this thread will now be locked.

See you soon with a legitimate question I hope.

The Moderation team

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
 Share

  • Recently Browsing   0 members

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