Jump to content

Search the Community

Showing results for tags 'condition'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • General
    • Announcements and Site News
    • Administration
  • AutoIt v3
    • AutoIt Help and Support
    • AutoIt Technical Discussion
    • AutoIt Example Scripts
  • Scripting and Development
    • Developer General Discussion
    • Language Specific Discussion
  • IT Administration
    • Operating System Deployment
    • Windows Client
    • Windows Server
    • Office

Categories

  • AutoIt Team
    • Beta
    • MVP
  • AutoIt
    • Automation
    • Databases and web connections
    • Data compression
    • Encryption and hash
    • Games
    • GUI Additions
    • Hardware
    • Information gathering
    • Internet protocol suite
    • Maths
    • Media
    • PDF
    • Security
    • Social Media and other Website API
    • Windows
  • Scripting and Development
  • IT Administration
    • Operating System Deployment
    • Windows Client
    • Windows Server
    • Office

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Location


WWW


Interests

Found 3 results

  1. Func z009() If FileExists("search\009\009.au3") Then #include <search\009\009.au3> EndIf EndFunc This wont work... Is there any workarround for this or I should do it in a different way?
  2. Hello Everyone, Is it possible to get shorter multiple condition expressions avoiding operator OR? for instance If @OSVersion In (Win_10, Win_7, Win8) Then. I got used to it in t-sql. Thank you.
  3. Hi all, I'm going crazy while I try and work out why a fairly simply if condition isn't working. I will try and explain it clearly, in the hope someone can find out the cause. The portion of the script for these if conditions is copied in below. The first PixelGetColor func is denoted in Screenshot 1, the RED dot signifies where the color is extracted from. The second PixelGetColor func is denoted in Screenshot 2, the YELLOW dot signifies where the color is extracted from. The script is tested for 3 scenarios, where 1. no resource is found (Screenshot 1), 2. multiple resources are found (Screenshot 2), and 3. only 1 resource is found (Screenshot 3). This application is being run via RDP hence I can't access the controls, and therefore relying on the pixel colours. The issue is, for all three scenarios, only the first If condition's first result is shown, even though the actual program shows the 3 screenshots for each of the three scenarios. Any ideas where I'm going wrong? If PixelGetColor(697, 446, 0xF0F0F0) Then ;If resource is not found, cancel out Sleep(200) MsgBox(64, 'Error', 'Resource is not found, therefore this pool will not be saved and will cancel out. Click OK to continue.') _Excel_RangeWrite($oWorkbook, 'CHFT Pools & RTE Rules', 'Fail', 'I' & $ColumnIRow) _Excel_RangeWrite($oWorkbook, 'CHFT Pools & RTE Rules', 'Resource not found. ' & $Notes, 'J' & $ColumnIRow) Sleep(500) WinActivate('Scheduling Help') Sleep(500) Send('{ENTER}') ;Click OK Sleep(500) Send('{SHIFTDOWN}{TAB}{SHIFTUP}{ENTER}') ;Click Cancel Sleep(500) Send('{SHIFTDOWN}{TAB}{TAB}{TAB}{TAB}{SHIFTUP}{ENTER}') ;Click Close Sleep(500) WinActivate('Scheduling: DB Flex Rule Tool - Inbox Pool Routing') Sleep(500) Send('{TAB}{ENTER}') ;Click Yes Sleep(500) WinActivate('Rules for Pool') Sleep(500) Send('{TAB}{TAB}{TAB}{ENTER}') ;Click Cancel Sleep(500) MouseClick('Primary', 1259, 653, 1) ;Click Cancel Else Send('{TAB}{TAB}{DOWN}') ;Find resource If PixelGetColor(725, 383, 0x3399FF) Then ;If there are multiple resources, cancel out Sleep(200) MsgBox(64, 'Error', 'There are multiple resources, therefore this pool will not be saved and will cancel out. Click OK to continue.') _Excel_RangeWrite($oWorkbook, 'CHFT Pools & RTE Rules', 'Redo', 'I' & $ColumnIRow) _Excel_RangeWrite($oWorkbook, 'CHFT Pools & RTE Rules', 'Multiple resources. ' & $Notes, 'J' & $ColumnIRow) Sleep(500) WinActivate('Scheduling Help') Sleep(500) Send('{TAB}{TAB}{ENTER}') ;Click Cancel Sleep(500) Send('{SHIFTDOWN}{TAB}{TAB}{TAB}{TAB}{SHIFTUP}{ENTER}') ;Click Close Sleep(500) WinActivate('Scheduling: DB Flex Rule Tool - Inbox Pool Routing') Sleep(500) Send('{TAB}{ENTER}') ;Click Yes Sleep(500) WinActivate('Rules for Pool') Sleep(500) Send('{TAB}{TAB}{TAB}{ENTER}') ;Click Cancel Sleep(500) MouseClick('Primary', 1259, 653, 1) ;Click Cancel Else ;Select the resource Send('{ENTER}') ;Select Order Physician MsgBox(0, '', 'save button clicks now') _Excel_RangeWrite($oWorkbook, 'CHFT Pools & RTE Rules', 'Complete', 'I' & $ColumnIRow) _Excel_RangeWrite($oWorkbook, 'CHFT Pools & RTE Rules', 'Success. ' & $Notes, 'J' & $ColumnIRow) ;Send('{TAB}{TAB}{TAB}{TAB}{TAB}{TAB}{ENTER}') ;Click Save EndIf EndIf
×
×
  • Create New...