Using Python script to refresh excel data connection on Alteryx server
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
In order to automate data sourcing, I have an excel file that is connected to an internal Sharepoint list that updates with new data when the data connection is refreshed. The connection to the Sharepoint list is authenticated by using my Windows login. (Had to use excel file as an intermediary, because I couldn't figure out how to connect to Sharepoint list directly from Alteryx)
I want this excel file to refresh every day at 8am and am looking to automate this.
I wrote Python script using XLwings library to use API connection to refresh the excel data connection, as seen below.
The Python script runs fine on my local device but when I load the code into Alteryx server using the python tool, the workflow errors out when it comes to reading the excel file.
Below is the python script.
Anyone have success using python to refresh excel data connections in Alteryx server?
- Labels:
- Connectors
- Python
- Server
- Sharepoint
- Workflow
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Anyone resolved this xlwings issue. If you are resolved then please let me know here.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
I was able to refresh an Excel file using a Python script from my desktop but not from the Gallery. I went thru Alteryx support, and they told me it isn't possible because of how Excel is designed. They said the Excel task requires an active user session. When running on desktop, you get an active user session. But, for security, Alteryx Gallery only runs as a non-interactive session that does not allow for interactive processes. Therefore, it didn’t matter what package or code I used. It would not work, and you cannot perform this task from a workflow run from the Alteryx gallery.
I wrote about it here - https://www.bigmountainanalytics.com/automation-with-powerautomate-alteryx-powerbi-excel/.

- « Previous
-
- 1
- 2
- Next »