O365 Activities - Upload File to Document Library top level
As of now, there is no direct way to get the root folder. However, we will have this feature in the next upcoming version of UiPath.MicrosoftOffice365.Activities package.
Kindly try the below approach and then check the behavior:-
- Use Find Files and Folder activity with a filter that retrieves a folder item which was created directly in the root folder -> mySharepointFolder
- Use Get Item Info to retrieve info about mySharepointFolder's parent, i.e. passing mySharepointFolder.ParentReference.ID as input -> mySharepointRootFolder (BTW, after you get the parentID's value, you can use it as a constant in your workflows that create items directly under root folder)
- Use Upload file activity to upload a file under root folder, i.e. mySharepointRootFolder .