4Ever Posted November 28, 2019 Share Posted November 28, 2019 Hello, How I can click this button in IE window (see the attached image) I have tried some scripts I found but is not working or I don't know how to apply. Example script: global $tags = $oIE.document.GetElementsByTagName("div") global $oInputs = _IETagNameGetCollection($oIE, $tags) For $oInput In $oInputs if $oInput.class == "Most Advanced" Then $oInput.Click ExitLoop EndIf Next Can someone give me a very simple working example? Link to comment Share on other sites More sharing options...
Danp2 Posted November 28, 2019 Share Posted November 28, 2019 There are several issues in the code you posted -- You would never pass $tags from the first line into the second line The element you want is a button, not a div The element's class isn't "Most Advanced" Try something like this -- $oButtons = _IETagNameGetCollection($oIE, "button") For $oButton in $oButtons If String($oButton.innertext) = "Most Advanced" Then _IEAction($oButton, "click") ExitLoop EndIf Next 4Ever 1 Latest Webdriver UDF Release Webdriver Wiki FAQs Link to comment Share on other sites More sharing options...
4Ever Posted November 28, 2019 Author Share Posted November 28, 2019 Wow... is working! Thank you! Thank you very much Danp2! ❤️ Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now