I have been pleased to find WebExecute for logging into web sites and downloading data that is updated daily from other sources, but Chrome keeps downloading the files to the factory default /download folder on my Macintosh. I have changed the preferences in Chrome to go to a more convenient folder for my purposes, but when starting a new session with Mathematica 12.1 Chrome always overrides my default and uses the "factory default." I've tried to use Mathematica code, to go to the Chrome preference page to override it, but....

WebExecute[session, {"OpenPage" -> "chrome://settings/downloads"}];
chgelemnt = WebExecute[session, "LocateElements" -> "HyperlinkText" -> "Change"]

returns {}.

I don't know how to manipulate the Javascript code that Chrome seems to set the download folder. Can anyone help me to either convince Chrome to always start up with my preference or help Mathematica do it for me?

I'm using this as a problem to help me to more fully understand how to manipulate Chrome and the web features of Mathematica. Thank you in advance, Steve


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.