aspnet-120624-components-file-management-file-manager-concepts-file-system-providers-onedrive-file-system-provider.md
The OneDrive file system provider (OneDriveFileSystemProvider) allows you to connect ASPxFileManager to OneDrive without user authentication.
Register your application with Azure Active Directory to get an access token that sets permissions for your application. This also allows your application to use OneDrive APIs to work with the App Folder.
Configure OneDrive Storage
Note
Register your account in Azure and Office365 for Business to configure OneDrive Storage.
Select Azure Active Directory / App registrations and click New application registration.
Enter the application’s name, type, and sign-on URL, and click Create.
Click Endpoints to get the Token Endpoint and Authorization Endpoint.
Click Settings to access your application’s settings. Use the “Application ID” field value to specify the clientID parameter for the RegisterOneDrive(String, String, String) method.
Click Reply URLs to specify URLs to which Azure Active Directory sends the authentication responses.
Click Required permissions and then click Add to specify permissions for Microsoft Graph.
Click Keys to create the clientSecret key and then use it as a parameter for the RegisterOneDrive(String, String, String) method.
Set the ASPxFileManager.ProviderType property to FileManagerProviderType.OneDrive to allow the file manager to manage files and folders in OneDrive’s App Folder.
The OneDriveFileSystemProvider class allows you to access the file and folder hierarchy, and manipulate these files in the file manager.
Do the following to connect ASPxFileManager to OneDrive:
Use the AccountManager.RegisterOneDrive method to register the OneDrive account in the global.asax file.
Use the ASPxFileManager.SettingsOneDrive property to specify the OneDrive account settings:
ASPxFileManager allows you to handle every request to OneDrive (the ASPxFileManager.CloudProviderRequest event).