Data Providers
Microsoft OneDrive
List files
5min
Often there is a requirement to list files or get one specific file from OneDrive and then interact with that file(s), whether for viewing, updating, deleting, or even downloading. The file's details are pulled to the device using the local data provider, after which you can work with the file, showing it in a list.
List OneDrive files
The following properties are required in the YAML:
- entity - path in OneDrive
- tokenType - OAuth token credentials name
There are a number of elements that can be used to display the file(s), for example, component.list, component.form with a dropdown, or jig.list.
- Getting or listing files from OneDrive does not download the file it just displays the details of the file from the path (entity) specified
- All files in a OneDrive directory can be listed and some directories may have many files. Consider the amount of items you want returned when creating the query for the local data provider.
- A delay or time lag of several minutes could be experienced when files are syncing between the device and OneDrive
The code example below provides an example of a list of invoices in the myfiles directory of OneDrive.
Updated 29 Apr 2024
Did this page help you?
Yes
No