Microsoft Dynamics CRM 2013 introduced a new entity image feature so we can have one image attribute and can use that to store an entity image. But we can have only one image attribute per entity. So in this article we will show how to get an image from Notes using JavaScript.
Microsoft Dynamics CRM stores all the notes and attachments in an annotation entity. Most of the out-of-box entities had relationships with this entity, but when creating our custom entity we can specifically select if we want to associate our custom entity with Notes or not using the following option under Communication & Collaboration. Keep in mind that once you enable this option, there is no supported way to disable this option, but if you are not sure, if you need Notes or not when you create an entity then it is better to leave this option un-selected, so that you can select this option later if required.
Note: The default size for a Notes attachment is 5 MB but if required you can increase this limit up to 32 MB.
For our demo purposes we will use an account entity that already has a relationship with a Notes entity. We will utilize the attachment feature to attach an image and use that in our HTML web resource for display. So basically we will implement the following procedure.
We can attach an image in Notes using the social pane in the Microsoft Dynamics CRM 2015, as in the following screen. Once the image is attached to Notes as in the following: