# Use OneDrive & SharePoint

> `UiPath.MicrosoftOffice365.Activities.Files.UseDriveCard`

`UiPath.MicrosoftOffice365.Activities.Files.UseDriveCard`

## **Description**

Selects an account to use for OneDrive and SharePoint automation. After you add this activity, add the activities that work with files from OneDrive and SharePoint in Use OneDrive & SharePoint. When you configure the activities added inside it, you can browse for files from OneDrive and SharePoint directly from Studio.

:::note
This activity only supports the Microsoft 365 activities that are found under the **Files** category. Use the [Microsoft Office 365 Scope](https://docs.uipath.com/activities/other/latest/productivity/microsoft-office-365-scope) activity if you want to work with other activities from the Microsoft 365 activities pack.
:::

## Project compatibility

Windows - Legacy | Windows

## **Configuration**

**Properties**

#### **Authentication**

* **Application Id** - Read-only, this is set when the account is added.
* **Tenant Id** - Read-only, this is set when the account is added.

#### Common

* **ContinueOnError** - If set, the remaining activities are executed if the current activity fails. This field supports Boolean values.
* **DisplayName** - The name displayed for the activity in the Designer panel. This property supports `String` variables and string formatted values.
* **Timeout** - How many seconds to wait for the browser authentication process to complete before generating an error. The default value is 90 seconds. This field supports only integers and `Int32` variables.

#### **Integration Service**

* **Use Integration Service** - If selected, the Integration Service manages the connection. This field supports Boolean values.

#### Misc

* **Private** - If this checkbox is selected, the values of variables and arguments are no longer logged at Verbose level.

## Using the Activity

The **Use OneDrive & SharePoint** activity can be used with or without a connection to the [Integration Service](https://docs.uipath.com/integration-service/automation-cloud/latest). Choose the desired method by selecting, or not, the **Use Integration Service** option from the **Properties** Panel. When the option is selected, it indicates that the Integration Service manages the [connection](https://docs.uipath.com/integrations/docs/connections).

#### **When using the Integration Service**

Add a new account or use an account connection you already added to the **Integration Service**.

* If a connection does not already exist, select **Add new account** from the dropdown menu to add a new account connection. A new browser window opens and you are guided through the process of creating a connection.
* If an account has already been added, it is automatically detected, and displayed in the menu.

#### **When not using the Integration Service**

Add a new account or select an account you have already added from a **Use OneDrive & SharePoint** activity.

* If you choose to add a new account and the Microsoft 365 application and tenant IDs are [added in Orchestrator](https://docs.uipath.com/activities/other/latest/productivity/adding-app-credentials-for-outlook-365-gmail-in-orchestrator), you are prompted to sign in to your Microsoft account.
* If you choose to add a new account and the Microsoft 365 application and tenant IDs are not added in Orchestrator, the **Add Exchange Account** dialog box opens to help you add the account:
 * **Authentication type** - Select one of the following options:
    * **Default** - Uses the UiPath application and tenant ID.
    * **My ID/Tenant** - Fill in the **Application ID** and **Tenant ID (when required)** fields with your organization's own application and tenant IDs.
  * **Use broker** - Add a checkmark to this option to use the Windows Authentication Manager (WAM) broker for interactive authentication. This option provides a more integrated authentication experience on Windows.
 * Select **OK** to sign in to your Microsoft account.
