I have created an script with Python using Selenium to access a third party website (sharepoint), authenticate, run a report and download an excel file to a folder. That works well. The problem is that when I want to automate this process with Windows Task Scheduler, it fails when trying to authenticate to the site since apparently the Shell.SendKeys functionality doesn't work in background processes. Popup
I was exploring other solutions to try to automatically authenticate and avoid the keyboard inputs since Selenium is not able to manage those kind of browser popups.
To achieve this and after hours of googling, I added the site to Trusted Sites in Internet Explorer and activated the option "Automatic Logon with current user name and password" Link
That worked in Internet Explorer, but when activated, I directly couldn't enter the site anymore from google Chrome which supposedly uses the same configuration for trusted sites from IE.
I also regenerated the python code to run over Internet Explorer (where the automatic login in works), but I get other popup at the end of the process to confirm "Open/Save" File where again I cannot manage to confirm with Selenium and I'm forced to use Shell.SendKeys which doesn't work with Task Scheduler so I'm stuck with this!!.
Anyone can help me to find a workaround?. Thanks in advance.