Wolfiesaxah Posted December 19, 2014 Share Posted December 19, 2014 Hi guys, I need to automate AutoIt so it clicks the image that is on a website. I don't want to use mouseclick using coordinates of that image as the image moves depending on page content. I need Autoit to search for these objects and click them so it's kind of a challenge for me. As you can see, the "Submit an offer" button is an image. It does not have tab index but my theory is if I instruct Autoit to click the <TD> ID "ct100_Td1" it could sort of click the "Submit an offer" image since that image is inside the "ct100_Td1" <td>. Any ideas how or what code to use for this? I am currently using send keys sending tabs until I get a focus on an object but this one doesn't have a tab index. '> Link to comment Share on other sites More sharing options...
Valuater Posted December 19, 2014 Share Posted December 19, 2014 IE.au3 should help #include <IE.au3> Local $oIE = _IECreate("http://www.google.com") Local $oForm = _IEFormGetCollection($oIE, 0) Local $oQuery = _IEFormElementGetCollection($oForm, 2) _IEFormElementSetValue($oQuery, "AutoIt IE.au3") _IEFormSubmit($oForm) good lick 8) Link to comment Share on other sites More sharing options...
Wolfiesaxah Posted December 20, 2014 Author Share Posted December 20, 2014 Oops sorry I should have mentioned it is Firefox. The company is officially using FF so I can't substitute IE. Also, how do I get those files you include? I can see everyone been using #include here but I have no idea where those included files or scripts would be coming from, I'm new to AI. What do I do to get those scripts and when I get them, what code should I be referring to for the problem stated above? Link to comment Share on other sites More sharing options...
Danp2 Posted December 20, 2014 Share Posted December 20, 2014 Look in the Example Scripts section. There's a UDF for FF that utilizes the MozRepl add-in. Latest Webdriver UDF Release Webdriver Wiki FAQs Link to comment Share on other sites More sharing options...
Wolfiesaxah Posted December 20, 2014 Author Share Posted December 20, 2014 I tried searching but only found Chrome UDF. What would be the title Dan? Also, is that UDF a custom add-in made by another auto-it user? If so that means when I have questions or things I need help with in using the UDF it will be hard searching for help if only a few knows and been using it? Is there like an official UDF for Firefox that AI users have been using for a while now? Too bad I was already excited seeing Valuater's sample code. I still have my fingers crossed that there's a solution for this problem. The website we are working on really made it hard for us by not using ordinary buttons and controls Link to comment Share on other sites More sharing options...
computergroove Posted December 20, 2014 Share Posted December 20, 2014 I dont know what official has to do with anything. This is a forum of Autoit users who like to donate their efforts to help others. '?do=embed' frameborder='0' data-embedContent>> is the unofficial firefox udf that's been used since 2009. I see it used and referenced a lot in the forum. Get Scite to add a popup when you use a 3rd party UDF -> http://www.autoitscript.com/autoit3/scite/docs/SciTE4AutoIt3/user-calltip-manager.html Link to comment Share on other sites More sharing options...
Danp2 Posted December 21, 2014 Share Posted December 21, 2014 What he said. Latest Webdriver UDF Release Webdriver Wiki FAQs Link to comment Share on other sites More sharing options...
Wolfiesaxah Posted December 21, 2014 Author Share Posted December 21, 2014 Ah gotcha, sorry it's my first time here. I am still learning AI and so if I run into confusing stuffs with FF UDF I need to be able to browse the internet and find solution. But you said it's been used since 2009 so most of the confusions or problems probably already exists, thanks so much. Link to comment Share on other sites More sharing options...
Wolfiesaxah Posted December 21, 2014 Author Share Posted December 21, 2014 I gave up on this, I was planning to use Autoit on FF for all employees at work but I can't have each of them go through the process of installing MozRepl and starting it and doing Telnet etch. I did all that and tried running the sample code of FF Click from http://english.documentation.ff-au3.thorsten-willert.de/ff_functions/_FFClick.php and all it gives are errors. I think I'll just stick to sending keys with AI. Link to comment Share on other sites More sharing options...
Wolfiesaxah Posted December 21, 2014 Author Share Posted December 21, 2014 I found salvation. Rather than following what the company uses as default browser, I will just have them use IE when using this auto-it. Valuater's IE solution works without complication. I am not sure why FF.au3 requires series of Telnet and other complicated steps while IE only requires to be included in a script. I don't even have to download IE.au3 since it's already included in the installation of AI. My script is working now. Link to comment Share on other sites More sharing options...
Danp2 Posted December 21, 2014 Share Posted December 21, 2014 While FF.au3 does require the MozRepl add-in, you shouldn't need to use Telnet or any other external apps. You can also set MozRepl to autostart. Another possible solution that would allow you to continue to use FF without the add-in is >IUIAutomation. Latest Webdriver UDF Release Webdriver Wiki FAQs Link to comment Share on other sites More sharing options...
Wolfiesaxah Posted December 21, 2014 Author Share Posted December 21, 2014 Thanks Dan, I will try to learn this IUI but I have to finish with IE for now so I can have something to present come Monday. Link to comment Share on other sites More sharing options...
junkew Posted December 21, 2014 Share Posted December 21, 2014 With iuiautomation you can build one script working on IE, FF, Chrome an no need for different libraries that would be nice to present on monday FAQ 31 How to click some elements, FAQ 40 Test automation with AutoIt, Multithreading CLR .NET Powershell CMDLets Link to comment Share on other sites More sharing options...
Wolfiesaxah Posted December 21, 2014 Author Share Posted December 21, 2014 Now that you mention it, that sound awesome! Ok I will try that 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