I am following below walkthrough by J. Lattimar to add Documents navigation in CRM form tab. It was working fine in classical forms, but for unified forms the steps are not working and instead throw exception like An Error as has occurred. Any idea how to get this working?
https://jlattimer.blogspot.com/2017/01/show-sharepoint-documents-on-main-form.html
Xrm.Page is deprecated, so you'll need to update this JS. Start here:
First of all, this is unsupported approach we are following, author clearly called it out.
In UCI why it broke - someone did investigation already
Replacing
Xrm.Page.context.getQueryStringParameters().etc
with "10069" ended up resolving this and currently works within UCI and Classic interfaces.
Actually couple of things to take care.
Like Hoffma said - Xrm.Page
is deprecated, you have to rewrite the code to refer formContext
from executionContext
Xrm.Page.context.getQueryStringParameters()
is not containing the etc
now, that's why breaking in UCI. You can supply the entity type code (etc) in the url manually
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.