tripros 16 Posted November 11, 2014 Report Share Posted November 11, 2014 Anyone successfully able to click a "Save As" when a dialog box pops up on a website to save a file? There is no other way to save this file other than to have the save as pop up, file is generated after clicking that link. Found a topic from a year and half ago, but the technique apparently doesn't work in latest version of ubot (5.5.1) after much testing. No other topics on the subject found. Interesting that when I add any commands after clicking the button to download the file, the download doesn't work, no popup at all. If I make that click the last command, the popup works fine, just have to click it manually. Thanks! Quote Link to post Share on other sites
UBotDev 276 Posted November 11, 2014 Report Share Posted November 11, 2014 Clicking there isn't the best way to solve that; Have you tried with "download file" and "save downloaded file"? Quote Link to post Share on other sites
tripros 16 Posted November 11, 2014 Author Report Share Posted November 11, 2014 Right, thanks, there is no option to download file, only click on the link and it generates the file on the fly and opens the save as dialog box. It's a series of checkboxes that you select the options from and then click a button link to generate the file. Did I understand your question properly? Quote Link to post Share on other sites
pash 504 Posted November 11, 2014 Report Share Posted November 11, 2014 Right, thanks, there is no option to download file, only click on the link and it generates the file on the fly and opens the save as dialog box. It's a series of checkboxes that you select the options from and then click a button link to generate the file. Did I understand your question properly? Why not show sample site and ubot code.Some problems require So easy to fix And understand your problems. i'm test on navigate("http://www.thinkbroadband.com/download.html", "Wait") wait for browser event("Everything Loaded", "") set(#downloadLink, $scrape attribute(<href="http://ipv4.download.thinkbroadband.com/5MB.zip">, "fullhref"), "Global") download file(#downloadLink, "{$special folder("Desktop")}\\TEST.zip")and navigate("http://www.thinkbroadband.com/download.html", "Wait") wait for browser event("Everything Loaded", "") click(<href="http://ipv4.download.thinkbroadband.com/5MB.zip">, "Left Click", "No") save downloaded file("{$special folder("Desktop")}\\TEST.zip") Quote Link to post Share on other sites
UBotDev 276 Posted November 11, 2014 Report Share Posted November 11, 2014 Right, thanks, there is no option to download file, only click on the link and it generates the file on the fly and opens the save as dialog box. It's a series of checkboxes that you select the options from and then click a button link to generate the file. Did I understand your question properly? If there is no URL to pass to "download file", you should use "save downloaded file" command instead. Quote Link to post Share on other sites
tripros 16 Posted November 11, 2014 Author Report Share Posted November 11, 2014 Unable to share the website, it's inside the WP admin of a client site and the download is in premium plugin options page. The code to generate the file is:<input type="submit" id="export_order" class="button-primary" value="Export Orders" /> There is no download link to the file in the source, the file is generated on the fly after submitting the button above. That's when the save as dialog box opens. Tried using the save downloaded file command and it saves a blank file since the save as dialog box doesn't open at all if there is any code placed after clicking the input button above. If the last line of code is the click on that button, it opens the save as dialog box just fine. Just then can't click it just manually. This is the code I've been playing with, I've tested most all the windows commands and suggestions made in the one post I found here on the forum: click(<value="Export Orders">, "Left Click", "No") plugin command("WindowsCommands.dll", "set active window", "Save As", "") plugin command("WindowsCommands.dll", "click dialog button", "Save As", "Save") I'm sure I'm not the first to run into this, right? Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.