Hi All,
I need to download PDF files from a SP site and store it locally using Alteryx. In Sharepoint, I tried to get the UNC path by going to Libraries tab and then click on 'Open in Explorer'. But this gave me a relative path "https://share.xx.net/sites/xxx_xxxxx/Lists/Shared Documents/9.xxxxx/xxxxx" . How do I use this link to download the files using alteryx? Or is there any other better way to do this ?
I am pretty new to Alteryx, so any guidance would be really appreciated.
Thanks
Antony.
Solved! Go to Solution.
I can download Excel files from SharePoint without any pb with the location of the file by right clicking on the file and looking at properties. However, for Macros located on SharePoint, that does not work at all. Any ideas?
All,
The easiest way that I have found to download a file from Sharepoint is as follows:
1.Open Sharepoint in Internet Explorer and browse your way to the file
2. Once you are to the file, copy the address
3. Truncate the address to just the sharepoint, i.e https://XXXX.sharepoint.com/sites/
4. Go to My Computer, right click and create Add a Network Location
5. Follow the wizard as you should just use the truncated address when setting up the new Network Location
6. Go to Alteryx and use the Input Data Tool.
7. You will now be able to click on the network location and then subsequently select the correct folders in order to get to the file.
8. Once selected, you are all set!
The other option is to use the Directory Tool
Follow steps 1-5
6. Go to Alteryx and use the Directory Tool
7.You can now click on teh network location and then subsequently select the correct folders, expect now, use the folder that your file is in vice selecting on the file itself.
8. You will now be able to manipulate all files in this directory, if you say, need to download all files (If so, you can use the download tool and a select tool).
Cheers!
Matt
@Reesetrain2 wrote:All,
The easiest way that I have found to download a file from Sharepoint is as follows:
1.Open Sharepoint in Internet Explorer and browse your way to the file
2. Once you are to the file, copy the address
3. Truncate the address to just the sharepoint, i.e https://XXXX.sharepoint.com/sites/
4. Go to My Computer, right click and create Add a Network Location
5. Follow the wizard as you should just use the truncated address when setting up the new Network Location
6. Go to Alteryx and use the Input Data Tool.
7. You will now be able to click on the network location and then subsequently select the correct folders in order to get to the file.
8. Once selected, you are all set!
The other option is to use the Directory Tool
Follow steps 1-5
6. Go to Alteryx and use the Directory Tool
7.You can now click on teh network location and then subsequently select the correct folders, expect now, use the folder that your file is in vice selecting on the file itself.
8. You will now be able to manipulate all files in this directory, if you say, need to download all files (If so, you can use the download tool and a select tool).
Cheers!
Matt
@Reesetrain2 I follow the steps and got an error message when i was following step 5 and this is the error message
To add on to @Reesetrain2, instead of truncating the address and having to select the location manually through the input or directory tool, you can use the Sharepoint option Open with Explorer. This will open the true directory location in Sharepoint and you can copy that address and follow the rest of his steps.
@Reesetrain2, @JustinLine and others,
Has anyone found a way to automate the connection to sharepoint? Such that the workflow could run on the Alteryx Server where we can't add network locations with our personal windows/sharepoint credentials in the mannor described above ...
I am still having problems trying to set up the network location as it keep coming up with the following
"the folder you entered does not appear to be valid, please choose another"
Anyone have come up with a solution for this?
Did you also try the SSL version? I.e.:
\\XXXX.sharepoint.com@SSL\DavWWWRoot\Sites
I found a solution for running on Designer (not yet working on Server).
SharePoint has a URL query string option for getting the folder openned in Explorer from the website. I've found that openning the folder in Explorer once starts a session that later enables me to access the SSL path for copying files to SharePoint. So, I built a workflow that can open this URL and then enables the copy to the SharePoint path. It does't work in Server for some reason, and I'm not sure that my admins will appreciate me open windows on the Server ... :)
The secret sauce is the URL, and especially the 'ExplorerWindowUrl' query string option:
https://your.sharepoint.com/Sites/your-site-collection/your%20folder%20name/Forms/AllItems.aspx?ExplorerWindowUrl=%2FSites%2Fyour%2Dsite%2Dcollection%2Fyour%20folder%20name
The Text Input tool in the snagit contains the above URL. The first Formula tool builds the command for the CMD tool:
'"C:\Program Files\Internet Explorer\iexplore.exe" "' + [URL] + '"'
If you need to continue the flow and control execution of the copy steps, just read the .bat file in the 'Input' section of the CMD tool and limit the output to 1 record to pass on to the next steps. In my case, I have an Append Fields tool to bring in some other information to use the in the second CMD tool.
The second Formula tool just has the paths needed for the copy and the following command for the CMD tool:
'copy "' + [NewFileFullPath] + '" "' + [SharePointPath] + '" > "' + [SupportingFilesPath] + 'copy_to_sharepoint_Messages.txt" 2>&1'
I use the 'Input' section of the CMD tool to read in the 'Messages.txt' file to review.
When run, it opens the URL in a new IE window, which in turn opens the Explorer window at the location I desire. This creates the session needed to allow the copy to run successfully.
Happy Alteryxing!
Can you please specify which tool you are using to download the files