Dynamics 365 Online and ADX Portal (Version 7.0.0024) SharePoint Grid Issue

Dynamics 365 Online and ADX Portal (Version 7.0.0024) SharePoint Grid Issue

Error #1: SharePoint Grid Loading issue

Issue Description

We started getting the error after we upgraded ADX Portal Version 7.0.0021 to ADX Portal 7.0.0024, and Dynamics CRM was upgraded from CRM 2016 to Dynamics 365.

The SharePoint document grid was working fine with ADX Portal version 7.0.0021 and Dynamics CRM 2016; however after it was upgraded to Dynamics 365 and ADX 7.0.0024, we started getting following errors:

Repro Steps

Step 1: Log in to the ADX Portal.

Step 2: Go to the Business Case List Navigation > create Edit Business case.

Step 3: Select the Business Case available to work on from the list (click to open ).

Step 4: Go to the Business Case > Documents tab.

The SharePoint grid is stuck when loading on the webpage.

Dynamics 365 Online and ADX Portal (Version 7.0.0024) SharePoint Grid Issue

Investigation

During debugging, it was breaking at line 132 as shown in the snapshot below:

In the traces, you can see it wasn’t able to parse ‘ &#32’ which got added in the handlebar tags of the SharePoint  html template.

Below is the SharePoint template and traces for reference:

SharePoint Template

Traces

handlebars.js:871 Uncaught Error: Parse error on line 1:
…ass=”toolbar } d
———————–^
Expecting ‘ID’, ‘DATA’, got ‘INVALID’
at Parser.parseError (handlebars.js:871)
at Parser.parse (handlebars.js:923)
at HandlebarsEnvironment.parse (handlebars.js:1272)
at compileInput (handlebars.js:1735)
at handlebars.js:1744
at Object. (sharepoint-grid.js:132)
at j (jquery-1.11.1.min.js:10)
at Object.fireWith [as resolveWith] (jquery-1.11.1.min.js:10)
at x (jquery-1.11.1.min.js:12)
at XMLHttpRequest.b (jquery-1.11.1.min.js:12)

Following resolution was suggested by Microsoft Support team after we logged the ticket with them.

The issue was related to encoding and was fixed by removing the Encoder Type from the web.config file of the ADX 7.0.0024 website.

  1. Go to the root directory of your website.
  2. Search for file web.config.
  3. Take backup of web.config file.
  4. Open the web.config file in Notepad or Visual Studio editor.
  5. Look for Encoder Type by doing CTRL+F.

  1. Remove the highlighted attribute from the below mentioned tag of web.config file.
  2. Save the web.config File
  3. Restart the website from IIS.

After this fix, we could see the SharePoint grid working properly on the ADX Portal.

Error #2: On Add Files of Share Point Grid we are getting the following Error:

Repro Steps:

Step 1: Login to the Government Portal.

Step 2: Go to the Business Case List navigation > create Edit Business Case.

Step 3: Select the Business Case available to work on from the list (click to open )

Step 4: Go to the Business Case > Documents tab.

Step 5: Click on the Add File button on the grid

Step 6 : Click Browse to add the file and click Add Filea:

Traces

The required anti-forgery form field “__RequestVerificationToken” is not present.

Resolution

Change the mime Type in the Add File function of the SharepointGrid.js

mimeType: “multipart/form-data; charset=utf-8”,

Use the Following Steps to fix the issue:

  1. Go to the path of the website (Installation Folder) > AdxStudio > XrmPortals > Dev > 7.0.0024 > Samples > MasterPortal

  1. Open the Js folder (Installation Folder) > AdxStudio > XrmPortals > Dev>7.0.0024 > Samples > MasterPortal > js.
  2. Edit the file sharepoint-grid.js and search for “Add Files “function.
  3. Change the existing mime type with mime Type: “multipart/form-data; charset=utf-8.

  1. Save the file.
  2. Restart the website from IIS.
  3. Browse and check by adding a document from the SharePoint grid of ADX Portal.

Published at Sun, 25 Jun 2017 17:00:14 +0000

Leave a Reply

Your email address will not be published. Required fields are marked *