Jump to content
  1. muchado

    muchado

  • Similar Content

    • By toto22
      I'm working on a script that does Auto-Log in for me. it looks like this :
      #include "UIAWrappers.au3" If ProcessExists("Advanced Dashboard.exe") Then Else Run("C:\Program Files (x86)\Advanced Dashboard\Advanced Dashboard.exe") EndIf sleep(1000) Local $oP6=_UIA_getObjectByFindAll($UIA_oDesktop, "Title:=Advanced Dashboard", $treescope_children) Local $oP5=_UIA_getObjectByFindAll($oP6, "Title:=;controltype:=UIA_PaneControlTypeId;class:=WindowsForms10.Window.8.app.0.34f5582_r9_ad1", $treescope_children) Local $oP4=_UIA_getObjectByFindAll($oP5, "Title:=;controltype:=UIA_PaneControlTypeId;class:=Shell Embedding", $treescope_children) Local $oP3=_UIA_getObjectByFindAll($oP4, "Title:=;controltype:=UIA_PaneControlTypeId;class:=Shell DocObject View", $treescope_children) Local $oP2=_UIA_getObjectByFindAll($oP3, "controltype:=UIA_PaneControlTypeId;class:=Internet Explorer_Server", $treescope_children) _UIA_Action($oP2,"setfocus") Local $oP1=_UIA_getObjectByFindAll($oP2, "Title:=WebBroker Login;controltype:=UIA_PaneControlTypeId;class:=", $treescope_children) Local $oP0=_UIA_getObjectByFindAll($oP1, "Title:=;controltype:=UIA_GroupControlTypeId;class:=", $treescope_children) Local $oUIElement1=_UIA_getObjectByFindAll($oP0, "title:=Password;ControlType:=UIA_EditControlTypeId", $treescope_subtree) ;~_UIA_action($oUIElement,"highlight") _UIA_action($oUIElement1,"click") Send("*****") Local $oUIElement2=_UIA_getObjectByFindAll($oP0, "title:=Login;ControlType:=UIA_ButtonControlTypeId", $treescope_subtree) ;~_UIA_action($oUIElement,"highlight") _UIA_action($oUIElement2,"click") Is there a way to check if "$oUIElement1" exists before I enter my password?
      I want my script to wait for "$oUIElement1" object to be present in-order to to do a log-in and do not rely on Sleep(1000). Thank you in advance!
    • By RomanY
      Hi all,
      I have simple question and can not find answer on it. I am working with WPF application and I want to automate it with Autoit. For now I found Inspect.exe tool which gives me all wpf controls, but how do I can use that controls to click some buttons or dropdown list?
      For example I have such a controls
      AutomationId:    "comboArrayType" or 
      Name:    "_Submit"
      Which autoit command can I use to handle this?
      Thanks and Regards, Roman Y
    • By 232showtime
      Good  day, its my first time creating script using UIA Wrappers. im kinda confused:
      #include "UIAWrappers.au3" $FrmClassName="TFrmMain" $Button1="Add" ;script is clicking all the button, if I use all the button name in this control->[CLASS:TBitBtn; INSTANCE:12] $Form=_UIA_getFirstObjectOfElement($UIA_oDesktop,"class:=" & $FrmClassName, $treescope_children) if isobj($Form) Then $Button2=_UIA_getFirstObjectOfElement($Form,"name:=" & $Button1, $treescope_subtree) $oInvokeP=_UIA_getpattern($Button2,$UIA_InvokePatternID) $oInvokeP.Invoke EndIf  
      but if I use the option name in [CLASS:TActionMainMenuBar; INSTANCE:1] it doesn't click any option in menu bar like "File", "View" or "Edit" and got error mesage
       
      #include "UIAWrappers.au3" $FrmClassName="TFrmMain" $Button1="File" ;doesnt click File, View or edit in menubar $Form=_UIA_getFirstObjectOfElement($UIA_oDesktop,"class:=" & $FrmClassName, $treescope_children) if isobj($Form) Then $Button2=_UIA_getFirstObjectOfElement($Form,"name:=" & $Button1, $treescope_subtree) $oInvokeP=_UIA_getpattern($Button2,$UIA_InvokePatternID) $oInvokeP.Invoke EndIf ;got error "C:\Program Files (x86)\AutoIt3\Include\UIAWrappers.au3" (514) : ==> Variable must be of type "Object".: $obj.getCurrentPattern($patternID, $pPattern) $obj^ ERROR ->09:03:47 AutoIt3.exe ended.rc:1
      +>09:03:47 AutoIt3Wrapper Finished.
      >Exit code: 1    Time: 1.383
       
       
       
       
×
×
  • Create New...