Connect an Adaptive Form to Microsoft® SharePoint

The Submit to SharePoint submit action allows you to seamlessly connect your Adaptive Form with a Microsoft® SharePoint storage. It sends the form data to the SharePoint storage of your choice after you submit the form.

AEM as a Cloud Service offers various out of the box submit actions for handling form submissions. You can learn more about these options in the Adaptive Form Submit Action article.

Advantages

Some of the advantages of submitting data from an Adaptive Form to the SharePoint storage are:

  • It facilitates the direct submission of form data to SharePoint, providing a centralized location for storing and managing information.
  • By applying the SharePoint’s access control and permissions features, it ensures that only authorized individuals can view or modify the submitted data.

Using Submit to SharePoint, you can:

Connect an Adaptive Form to SharePoint Document Library connect-af-sharepoint-doc-library

To use the Submit to SharePoint Document Library Submit Action in an Adaptive Form:

  1. Create a SharePoint Document Library Configuration: It connects AEM Forms to your Microsoft® Sharepoint Storage.
  2. Use the Submit to SharePoint submit action in an Adaptive Form: It connects your Adaptive Form to configured Microsoft® SharePoint.

Create a SharePoint Document Library configuration create-sharepoint-configuration

To connect AEM Forms to your Microsoft® Sharepoint Document Library storage:

  1. Go to your AEM Forms Author instance > Tools > Cloud Services > Microsoft® SharePoint.

  2. Once you select the Microsoft® SharePoint, you are redirected to SharePoint Browser.

  3. Select a Configuration Container. The configuration is stored in the selected Configuration Container.

  4. Click Create > SharePoint Document Library from the drop-down list. The SharePoint configuration wizard appears.

    Sharepoint configuration

  5. Specify the Title, Client ID, Client Secret and OAuth URL. For information on how to retrieve Client ID, Client Secret, Tenant ID for OAuth URL, see Microsoft® Documentation.

    • You can retrieve the Client ID and Client Secret of your app from the Microsoft® Azure portal.
    • In the Microsoft® Azure portal, add the Redirect URI as https://[author-instance]/libs/cq/sharepoint/content/configurations/wizard.html. Replace [author-instance] with the URL of your Author instance.
    • Add the API permissions offline_access and Sites.Manage.All to provide read/write permissions.
    • Use OAuth URL: https://login.microsoftonline.com/tenant-id/oauth2/v2.0/authorize. Replace <tenant-id> with the tenant-id of your app from the Microsoft® Azure portal.
    note note
    NOTE
    The client secret field is mandatory or optional depends upon your Azure Active Directory application configuration. If your application is configured to use a client secret, it is mandatory to provide the client secret.
  6. Click Connect. On a successful connection, the Connection Successful message appears.

  7. Now, select SharePoint Site > Document Library > SharePoint Folder, to save the data.

    note note
    NOTE
    • By default, forms-ootb-storage-adaptive-forms-submission is present at selected SharePoint Site.
    • Create a folder as forms-ootb-storage-adaptive-forms-submission, if not already present in the Documents library of the selected SharePoint Site by clicking Create Folder.

Now, you can use this SharePoint Sites configuration for the submit action in an Adaptive Form.

Use SharePoint Document Library Configuration in an Adaptive Form use-sharepoint-configuartion-in-af

You can use the created SharePoint Document Library configuration in an Adaptive Form, to save data or generated Document of Record in a SharePoint folder. Perform the following steps to use a SharePoint Document Library storage configuration in an Adaptive Form as:

  1. Create an Adaptive Form.

    note note
    NOTE
    • Select the same Configuration Container for an Adaptive Form, where you have created your SharePoint Document Library storage.
    • If no Configuration Container is selected, then the global Storage Configuration folders appear in the Submit Action properties window.
  2. Select Submit Action as Submit to SharePoint.
    Sharepoint GIF

  3. Select the Storage Configuration, where you want to save your data.

  4. Click Save to save the Submit settings.

When you submit the form, the data is saved in the specified Microsoft® Sharepoint Document Library Storage.
Folder structure to save data is /folder_name/form_name/year/month/date/submission_id/data.

Connect an Adaptive Form to Microsoft® SharePoint List connect-af-sharepoint-list

To use the Submit to SharePoint List Submit Action in an Adaptive Form:

  1. Create a SharePoint List Configuration: It connects AEM Forms to your Microsoft® Sharepoint List Storage.
  2. Use the Submit using Form Data Model in an Adaptive Form: It connects your Adaptive Form to configured Microsoft® SharePoint.

Create a SharePoint List Configuration create-sharepoint-list-configuration

To connect AEM Forms to your Microsoft® Sharepoint List:

  1. Go to Tools > Cloud Services > Microsoft® SharePoint.

  2. Select a Configuration Container. The configuration is stored in the selected Configuration Container.

  3. Click Create > SharePoint List from the drop-down list. The SharePoint configuration wizard appears.

  4. Specify the Title, Client ID, Client Secret and OAuth URL. For information on how to retrieve Client ID, Client Secret, Tenant ID for OAuth URL, see Microsoft® Documentation.

    • You can retrieve the Client ID and Client Secret of your app from the Microsoft® Azure portal.

    • In the Microsoft® Azure portal, add the Redirect URI as https://[author-instance]/libs/cq/sharepointlist/content/configurations/wizard.html. Replace [author-instance] with the URL of your Author instance.

    • Add the API permissions offline_access and Sites.Manage.All in the Microsoft® Graph tab to provide read/write permissions. Add AllSites.Manage permission in the Sharepoint tab to interact remotely with SharePoint data.

    • Use OAuth URL: https://login.microsoftonline.com/tenant-id/oauth2/v2.0/authorize. Replace <tenant-id> with the tenant-id of your app from the Microsoft® Azure portal.

      note note
      NOTE
      The client secret field is mandatory or optional depends upon your Azure Active Directory application configuration. If your application is configured to use a client secret, it is mandatory to provide the client secret.
  5. Click Connect. On a successful connection, the Connection Successful message appears.

  6. Select SharePoint Site and SharePoint List from the drop-down list.

  7. Select Create to create the cloud configuration for the Microsoft® SharePointList.

Use the Submit using Form Data Model in an Adaptive Form use-submit-using-fdm

You can use the created SharePoint List configuration in an Adaptive Form, to save data or generated Document of Record in a SharePoint List. Perform the following steps to use a SharePoint List in an Adaptive Form as:

When you submit the form, the data is saved in the specified Microsoft® Sharepoint List Storage.

NOTE
In Microsoft® SharePoint List, the following column types are not supported:
  • image column
  • metadata column
  • person column
  • external data column
recommendation-more-help
fbcff2a9-b6fe-4574-b04a-21e75df764ab