Skip to main content

Hi

 

I have a form that is uploading files to a sharepoint doc. lib. but needs to be able to upload the files to a subfolder, which can be 2-3 subfolders. I can get all of the subfolders from a dropdown get folders, but when the file is uploaded it is creating the folder at the top folder, then uploading the file into the newly created folder, instead of uploading the file to sub, sub subfolder. How can I either display the full path in the dropdown and then have the file get uploaded to that third level subfolder. 

Hi,

You can try to configure the dropdown which displays the folder to set the value to the Link to Item property. That way, you will get the complete link to the folders and subfolders.

eg.  https://portal.denallix.com/TestLib/SubA/SubB




On your form/view, add a data label and assign the following expression:
REPLACE([Your dropdown list control], [SharePoint Library URL], [Empty String])

The SharePoint Library URL would be the URL of your library. In the example above, you can just put: https://portal.denallix.com/TestLib/

On your call to Upload Document, pass the data label to the Folder parameter. If I want to upload a document to SubA/SubB, I can just choose SubB from the dropdown and the data label will be displayed as SubA/SubB. The document will then be uploaded to the correct subfolder.


Hope this helps.


great fix. I was actually mad at myself for not finding this same solution
sometimes thinking easier is the solution!!!

THANKS!!!

Reply