Skip to main content

Updated To Version 1.7 - Azure Blob Storage For Storing Microsoft Dynamics 365 Attachments

In another post I talked about using Azure Blob Storage to store CRM attachments in Azure rather then in CRM.  Today I installed the app in a clients CRM system and found that Microsoft Labs updated the App to version 1.7.  This change had a lot of updates from UI to how to setup notes attachment movement.  Also they now allow for moving of existing attachments.  Here is the updated steps:

1) Go To AppSource
2) Install the Attachment Management App by clicking the "Get It Now" button under the image.
3) While its installing go to Azure and setup your blob storage account.
4) For each CRM instance you will need to setup 2 containers in your blob storage.  One is for email attachments and the other is for notes attachments.  So if you have a production instance and sandbox instance you will need to have 4 containers (DevEmails, DevNotes, ProdEmails, ProdNotes).  If you want to separate note attachments by entity, then create one container per entity.  The DevNotes or ProdNotes will be used as the default location, unless you specific a specific entity container for notes.
5) Still in Azure click on "Shared Access Signatures"  Here you will setup your SAS key.  Complete all sections and click on "Generate SAS".
6) Copy the SAS key, we will need it later.
7) Go back to CRM and check to make sure the attachment management app finished installing.
8) In setting -> Customization -> Solutions, click on publish all customization.
9) Refresh your screen.
10) You will see a new link in the navigation bar for Azure Attachment Storage. Click on it and then on Azure Attachment Storage Setup.


11) Fill in the fields.
      - Name = The name of the blob storage account in Azure
      - SAS Token = Get this from step 6
      - Notes Attachment Container = Name of the container in Azure
      - Email Attachment Container = Name of the container in Azure
12) Click Confirm.
13) Go back to the navigation bar and click on Notes Attachment Entity Settings.  Here is where you choose what entities you want to upload notes attachments to azure.  You must choose each entity.  If you setup multiple containers in step 4 then you need to specify those here. ***ANYTHING WITH ADX_ IN THE ENTITY NAME SKIP.  DO NOT ADD THESE TO MOVE THE ATTACHMENTS TO AZURE.  IT WILL BREAK YOUR CRM PORTAL.*** I did notice that if I selected all at once the page did seem to hang.  So I did it in groups and it worked fine.  Make sure to leave all entities selected that you want to automatically move attachments for.  Once unselected they will stop moving.
That's it, your setup is now complete.

If you need to move existing attachments to Azure then do the following:
1) In the navigation click on Azure Attachment Storage and the on Reports and admin.
2) Choose what you want to move in the left hand column and click  on Move to Blob.  You should see the number on the left decrease and the number on the right increase.


For additional information including setting up bulk attachment upload see the User Guide.

Comments

  1. This comment has been removed by the author.

    ReplyDelete
  2. My customer wanted to migrate data from Dynamics 365 to Azure Storage and followed this instruction to set up. However, after clicking on move to blob, nothing happens. Could you please help my customer find out how to migrate the existing data? Thanks.

    ReplyDelete
    Replies
    1. After inputting the information in step 11 did you set the entities in step 13. Also check the SAS connection string, it could be the the connection string is incorrect. I know in Azure you will see an SAS connection string, you cna't use this one, you have to build a new one and it has to include a date time for start and end. For start go one day in the past and then extend it out as far you want to.

      Delete
    2. Thanks for your help. My customer has managed to get the process working and has some feedback.
      “When the point 13 section is performed with the documentation snippet that you had provided, the entities must be left selected.”

      Delete
    3. Thank you for the feedback. I have added that information to step 13. Glad it is working for you.

      Delete
  3. I am happy to find this post Very useful for me, as it contains lot of information

    indiaunimagined
    Technology

    ReplyDelete
  4. A good blog for the people who really needs information about this. Good work keep it up.

    Article submission sites
    Education

    ReplyDelete

Post a Comment

Popular posts from this blog

Dynamics Set IFrame URL - D365 v8 vs. D365 v9

While doing client work, I came across a problem with setting an IFrame URL dynamically.  The underlying issue was that the sandbox instance is on v8 of Dynamics 365 and production is on v9 of Dynamics 365.  The reason for this was because this client was setup around the time that Microsoft rolled out v9.  Anyways, JavaScript that I wrote to dynamically set the URL of the IFrame wasn't working in the v9 instance.  This was because of changes that Microsoft made to how IFrames are loaded on the form and also changes to JavaScript.

Here is my v8 setup:
JavaScript runs OnLoad of contact form.  This works because of how IFrames are loaded in v8.  You can also run it on either a tab change (hide / show) or OnReadyStateComplete event of the IFrame.  Depending on your setup you will need to choose which is best for you.  For me in this case it was the OnLoad event.Here is the JavaScript: function OnLoad() { //Get memberid var value = Xrm.Page.data.entity.attributes.get…

Multi-Select Option Sets Missing setVisible() for JavaScript (Workaround)

It is common practice in Microsoft Dynamics 365 to use Business Rules to show and hide fields on a form.  But, with that addition of multi-select option sets, you can't do this.  So the next logical step is to use JavaScript.  There is just one small problem, there is no setVisible() function for multi-selection option sets.  Here are the controls we do have access too, as of this post:

So, how can we dynamically show / hide multi select option sets?  The easiest way is to use a section.  Place a new section on you form.  Then you will need to use JavaScript to get the tab and section by name.  Once you have that, you can dynamically show / hide the section to make the multi-selection option set show and hide.  Here is an example of the JavaScript:

function ShowHide(executionContext) { //Create the form context var formContext = executionContext.getFormContext(); var contactStatus = formContext.getAttribute("Field Name").getValue(); var tabObj = fo…

XrmToolBox Bulk Attachment Manager - Version 2018.2.2.7 Released!

Today I have published version 2018.2.2.7 of my XrmToolBox plugin.  The purpose of this plugin is to make it easy to download and backup attachments in CRM.  This release is a major release as it is the first built version with all pieces working.  The first version only had note downloads working.

Overview of Plugin:
Current Version: 2018.2.2.7Purpose: Download Attachments and E-Mail attachmentsGitHub Link.GitHub Wiki Link.Nuget Package Link.How To Use The Tool: Launch XRMToolBox.Connect to organization.Step 1, choose what you want to download. (Once a choice is made, Step 2 becomes usable)Notes - Download attachments from note entity.E-Mail - Download attachments from emails.Both - Downloads attachments from notes and emails entities.Step 2, choose if you want to download all attachments in the system or specific attachments.  All Attachments - This will search the chosen entity to find all records that have an attachment and download them.Click on "Browse" and choose where t…