Downloading Excel File from a URL
- 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
I receive and email from our training software that includes a URL Excel file link for the excel data.
Example: www.compliancewire.com/CustomerData/Temp/sample.xlsx (The data is confidential so I couldn't use a real url)
I am trying to use the download tool to download this file and then use a dynamic input tool to use the data.
When I configure the Download Tool to Output to a File it works and I can open the file with excel. When I attempt to use the dynamic input tool (or a regular input tool) I get the following error:
Error: Input Data (5): Target Excel file may be corrupt! Cannot find required file, or element within file: xl/styles.xml
Also when I try to choose a Table Name the there are none I can click
What I have tried
- Changing the .xlsx file format to xls, xlsm, etc
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi @fitzgerald2022 ,
I couldn't see a file at that URL (so used another) but does the attached do what you were looking for?
------
If I have solved your query please mark this solution as accepted - thank you!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
That is what I want it to do but it doesn't work with my specific url. I can't give you my specific url because it contains confidential information but I think it is sent in a newer version of excel than the example you gave me.
When looking at the Header information I noticed a difference in the content types
My URL Header Information:
HTTP/1.1 200 OK
Date: Thu, 04 Apr 2019 20:00:54 GMT
Connection: Keep-Alive
Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet,text/csv
Last-Modified: Wed, 03 Apr 2019 14:18:13 GMT
Server: Microsoft-IIS/7.5
X-Powered-By: ASP.NET
Content-Encoding: gzip
Age: 0
Accept-Ranges: bytes
Content-Length: 63434
Your URL Content Type:
HTTP/1.1 200 OK
Date: Thu, 04 Apr 2019 19:45:17 GMT
Server: Apache/2
Last-Modified: Thu, 05 Jul 2018 12:25:28 GMT
ETag: "17d5d-5703fa47dadc5-gzip"
Accept-Ranges: bytes
Vary: Accept-Encoding,User-Agent
Content-Encoding: gzip
Transfer-Encoding: chunked
Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
I can do a save as of the temp document and then it works fine with my regular input tool and dynamic input tool
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
It definitely seems like something to do with the encoding of that specific Excel file. It looks like errors with "/xl/styles.xml" are a known issue in Excel. One of the suggested fixes is to save as .xls instead of .xlsx which you could do by amending the filename, but you did say in your original message that you'd already attempted changing the extension. Hmm - tricky one!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Yeah I have tried saving it as an xls and it wouldn't work. I wasn't sure if there was a tool that could change the encoding after downloading or something like that. This has been very tricky and driving me nuts!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
I found a solution to the problem
- I saved the download .zip file
- Using the dynamic input tool I found the sheet1.xml file and checked the Return Outer XML option
- This allowed me to see every row in the excel sheet
- Parsed out the data I needed
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Nicely done!!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
@jamielaird this is great! Thanks for sharing.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi Zackfitz,
Thanks for this solution.
But in my case, the download file is a direct .xlsx file and not a zip file. I am still facing the issue.
Would it be possible for you to share the workflow here?
Regards,
Panch
