SharePoint Activity - Create Folder


I am using UiPath.MicrosoftOffice365.Activities to create a folder on a SharePoint Document Library. THe issue is that if the folder exists, an error occurs and the process ends. Question is how do I check if the folder exists before creating the folder?

Thanks in advance.

check if you can sync the folder to your machine and use path exist activity

Hi @Lak_Ui ,

Thank you for the response. I want this process on an unattended mode on orchestrator server, so I’m not able to sync the folder on the server. Are there any other option?

Hey @Weller_Ashley-Ivan

You need to get the folder first and see if it has retrieved a result or not which obviously confirms.


Hi @Weller_Ashley-Ivan,

If you have a folder already in the document library, find it with Find Files and Folders , then use Get File/Folder passing in the existing folder’s ParentReference.Id as input to get the root folder as a DriveItem , then use that in Create Folder to create the new folder you want under the root.

Additional Reference on how to get the ParentReference.Id : UiPath KB Article

Hope that helps !


1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.