Investigating Invalid Arguments errors in Dynamics 365 CRM

In case you encounter errors when working in Dynamics 365 CRM as a Developer, you’ll often see error popups that don’t let you have the option to Download Log File.

And it looks like this –

Now, since you don’t have anything to look at the log, let’s see how we can at least identify what is being called which is throwing this error.

Open Browser’s Dev Tools

  1. Open the Dev Tools by pressing F12 in any browser. In my case, I’m using Chrome.
    Go to the Network tab and clear the logs if needed as shown below.

  2. Now, perform the operation which caused the issue.

  3. And in the Dev Tools, you’ll see it populate

  4. Now, if you expand the one with the error, you’ll see the details of the issue.


Hope this was useful!

Here are some Power Automate posts you want to check out –

  1. Blocking Attachment Extensions in Dynamics 365 CRM
  2. Upgrade Dataverse for Teams Environment to Dataverse Environment
  3. Showing Sandbox or Non Production Apps in Power App mobile app
  4. Create a Power Apps Per User Plan Trial | Dataverse environment
  5. Install On-Premise Gateway from Power Automate or Power Apps | Power Platform
  6. Co-presence in Power Automate | Multiple users working on a Flow
  7. Search Rows (preview) Action in Dataverse connector in a Flow | Power Automate
  8. Suppress Workflow Header Information while sending back HTTP Response in a Flow | Power Automate
  9. Call a Flow from Canvas Power App and get back response | Power Platform\
  10. FetchXML Aggregation in a Flow using CDS (Current Environment) connector | Power Automate
  11. Parsing Outputs of a List Rows action using Parse JSON in a Flow | Common Data Service (CE) connector
  12. Asynchronous HTTP Response from a Flow | Power Automate
  13. Validate JSON Schema for HTTP Request trigger in a Flow and send Response | Power Automate
  14. Converting JSON to XML and XML to JSON in a Flow | Power Automate

Thank you!

Advertisement

Enable Plug-in Profiler in Settings area in SiteMap in Dynamics 365 | [Quick Tip]

In case you are wondering why Plug-in Profiles under Extensions and Extensions itself don’t appear in your SiteMap because you want to debug from the Persist To Entity option?

But your Settings area still looks like this and don’t see Plugin-Profiles?

Install Plugin Profiler

You’ll need to install Plugin Profiler.

  1. Open Plugin Registration Tool and login to the environment.
    You should see an Install Profiler button. That’s the reason the Profile is not yet installed on the environment and it’s now showing in SiteMap.


  2. Now, when you click on Install Profiler, it’ll install the Profiler to the environment.


  3. Once this is installed, you’ll see it show in the SiteMap in Settings area.


  4. Also, if you notice the Solutions, a Managed Solution would also be installed which will SiteMap (it indicates the update that Plugin Profiles has been added to the SiteMap)


  5. Also, if you Uninstall the Plugin Profiler, the Managed Solution will be removed and also this will take Plug-in Profile off the SiteMap.
  6. Also, there’s another way to remove the Plugin Profiler – Workaround to get Plugin Profiler from the Unified Interface in D365 CE

Hope this was helpful!

Here are some more Dynamics 365 Admin related posts you might want to check –

  1. Disable Recent Records from Dynamics 365 Lookup Control | Model-Driven Apps [Quick Tip]
  2. Language format for Whole Number field in Dynamics 365 CE
  3. Custom Help Pages and Guided Tasks for Unified Interface in Dynamics 365
  4. Make Managed fields Required in Dynamics 365 – Managed Properties Error [Workaround] | D365 CE Quick Tip
  5. Sign up for a Dynamics 365 Project Operations (Lite Deployment) environment and provision a new instance | Power Platform
  6. Filter records in a View owned by a Team you are a member of | Dynamics 365 CRM
  7. Show custom ribbon button based on Security Role of the logged in User in Dynamics 365 | Ribbon Workbench in XrmToolbox
  8. Make On-Demand Flow to show up in Dynamics 365 | Power Automate

Thank you!

Advanced Lookup in Model-Driven Apps | Power Platform

Here’s a super useful feature now available in Dynamics 365 for Model-driven Apps called as Advanced Lookups.

Turn on Advanced Lookup from Behavior Settings

You’ll need to go to the Power Platform Admin Center (PPAC) –

  1. Navigate to Behavior

Using Advanced Lookups

Here’s how the experience will be for you while using Advanced Lookups

  1. Now, once this is enabled, in Dynamics 365 – for example – a Parent Account lookup on Account will work as below –


  2. And it will open this dialog where you’ll see a much wider view of the Advanced Lookup and help your find the record using navigation/filtering options


    Denoted by Red arrow, you can even switch between different available System Views for the selected Table (entity).
    Denoted by Green, you can either create a record on the fly or filter to show only records that you own.
  3. Once you select to switch a view, you’ll be able to select between different System Views.




  4. And once you select a record (Of course you can only select 1 record at a time) and click done, it’ll be done.


    And it’ll be added to the lookup field as follows.


  5. Also, only the views which you’ve selected in your Model-Driven App will appear and not all. For Example, in the Sales Professional App, I’ve selected only a handful of views and not all. So, only those will show up.


  6. Also, please make sure when you select Views and not all, please make sure you do select the Lookup View


  7. Else, if you don’t select this view, it’ll result in Runtime errors which I observed while trying to experiment on what views I can select. Hence, make sure that you select the Lookup Views along with other views which you require.

Here are Canvas Power Apps / Model-Driven Apps which you might like –

  1. New App Designer for Model-Driven Apps | Power Platform
  2. Rich Text Control for Canvas and Model-Driven App | Quick Tip
  3. Form Access Checker in new Power Apps Form Designer | Model-Driven Apps in Dynamics 365
  4. How to add Rating Values to Rating Models in D365 Field Service and PSA
  5. Language format for Whole Number field in Dynamics 365 CE
  6. Custom Help Pages and Guided Tasks for Unified Interface in Dynamics 365
  7. Filter records in a View owned by a Team you are a member of | Dynamics 365 CRM
  8. Show custom ribbon button based on Security Role of the logged in User in Dynamics 365 | Ribbon Workbench in XrmToolbox
  9. Duration field in Dynamics 365 converts Hours value to Days in Dynamics 365 | [Flow Workaround to convert in Hours and Mins]
  10. Find deprecated JS code used in your Dynamics 365 environment | Dynamics 365 v9 JS Validator tool | XrmToolBox

Thank you!

Admin Center URLs under M365 – Power Platform, Teams, SharePoint, Power BI

Here’s a quick summary of the Admin Center URLs of each of these Dynamics 365 / Power Platform Admin Centers –

All Admin Centers under M365 Admin Centers

Here’s the link to all Admin Center under your O365 tenant based on your subscription and your Role in the tenant – https://admin.microsoft.com/Adminportal/Home?source=applauncher#/alladmincenters

Power Apps / Power Automate / Power Platform Admin Center (PPAC) / Dynamics 365

Here’s how you can access the Power Platform Admin Center

  1. http://admin.powerplatform.com/ – It will redirect to –
    https://admin.powerplatform.microsoft.com/

    From here, you can access the D365 Environments

Power BI Admin Portal

Here’s the URL for the Power BI Admin Portal – https://app.powerbi.com/admin-portal

It’ll open up the Admin Portal which looks like this

SharePoint Admin Center

Here’s how you can check the link of the Admin Center for SharePoint – https://cft158-admin.sharepoint.com/

So basically, https://[domain]-admin.sharepoint.com/

Here, domain is the one that you created while creating the tenant. Example: you didn’t add a custom domain and your domain then look like this in your username admin@[cft158].onmicrosoft.com

And it will look like this –

Teams Admin Center

Here’s a link to the Teams Admin Center and it’ll look like below- https://admin.teams.microsoft.com/dashboard

Hope this was useful.

Here are some more D365 / Power Platform Admin related posts which might be helpful –

  1. Turn Teams On / Off at Org Level, provisioning users | M365 Admin Center Tip
  2. Convert environments between Production and Sandbox | Power Platform Admin Center [Quick Tip]
  3. Create new Sandbox and copy Production over to it in PowerPlatform Admin Center
  4. New ‘Capacity’ analytics on PowerPlatform Admin Center
  5. Create new CDS Environment and Database quickly from PowerApps Admin Center
  6. Sign up for a Dynamics 365 Project Operations (Lite Deployment) environment and provision a new instance | Power Platform

Thank you!

Filter records in a View owned by a Team you are a member of | Dynamics 365 CRM

In Dynamics 365, “My” views show records owned by the System Users themselves. Let’s look at how you can have views that let’s you filter records based on the Owner Team which you are a part of.

Scenario

Let’s assume the below scenario in terms of Contacts entity. All users have Contacts owned by them. Out-of-the-box views show filter “My” views only by Owner field.

  1. Default My Active Contacts view will show you Contacts you are Owner of. (Similarly, this could apply to every other record as well)
    Example: Amit is logged in and he is seeing his Contacts under My Active Contacts




  2. Now, Amit is also part of a Sales Team which is an Owner Team in Dynamics 365 CRM/CE


  3. And, there is a Contact which is assigned to the Sales Team itself and not an individual user.


    I’ll just expand the header and show you the Owner

  4. So, we’ll make this Contact also appear for Amit on his new My Team(s) Contacts’ view. You can call your view something else as well.
    So let’s see we can do this.

Create a new View – Edit Filter Criteria

In order to make the Owner Team’s record available, we’ll have to work by creating a new view and editing the Filter Criteria of the new view. Let’s see how –

  1. I’ve created a new view called as My Team(s) Contacts. And I’ll start by editing the criteria itself.



  2. Start by selecting Owning Team (Team) under the Related section of the fields selection drop-down.



    Under that, open the drop down to expand it’s related records.


  3. Under Owning Team (Team), look for Users. Notice that it doesn’t have any entity name mentioned in brackets like other fields in the list. Meaning, it is the sub-grid i.e. Child Record list under the Team record.

  4. Once you select the Users, expand the dropdown under Users which will be the fields of the System User record itself.


  5. In this list, select User itself. This is the GUID of the User record. Pro Tip: Any field with the name of the entity itself is a GUID/Primary Key of the entity record itself.

  6. And in this last selection, you’ll notice that the Current User is already selected for you.

  7. That’s it. Save your criteria and publish the changes.
    Let’s see the results.

Result

Now, if you navigate to the new view you created with the selected criteria, you’ll see the records Owned by Teams which the logged in user is a part of –

Caveat – Clubbing into 1 view (Owner + Owning Team’s Member) is not possible

Let me point out a caveat right away before we proceed – In case if you are wondering that we can do this in the same view by adding more ‘Related’ entity criteria which will look like the below – it won’t work! 😦

Because, the Filter Criteria will not consider (or let you select these rows in any order) and let you make it in an OR group.
By Default, this is an AND group i.e. a Field + Related criteria can’t be grouped together.
If you set the above criteria in any order, it’ll end up returning 0 results.


Hope this was useful!

Here are some more Dynamics 365 related posts you might want to check –

  1. Use Rich-Text Control for Multiple Lines of Text in Dynamics 365 CE | Quick TipDuration field in Dynamics 365 converts Hours value to Days in Dynamics 365 | [Flow Workaround to convert in Hours and Mins]
  2. Import lookup referencing records together in Dynamics 365 CRM | [Linking related entity data during Excel Import]
  3. Show custom ribbon button based on Security Role of the logged in User in Dynamics 365 | Ribbon Workbench in XrmToolbox
  4. Connecting XrmToolBox to an MFA enabled Dynamics 365 environment | Azure AD
  5. Form Access Checker in new Power Apps Form Designer | Model-Driven Apps in Dynamics 365
  6. Use Rich-Text Control for Multiple Lines of Text in Dynamics 365 CE | Quick Tip
  7. Ribbon button visibility based on a field value in Dynamics 365 | Ribbon Workbench
  8. Make On-Demand Flow to show up in Dynamics 365 | Power Automate
  9. Find deprecated JS code used in your Dynamics 365 environment | Dynamics 365 v9 JS Validator tool | XrmToolBox
  10. Remove ‘This Email has been blocked due to potentially harmful content.’ message in Dynamics 365 Emails | OrgDbSettings utility

Thank you!

Use Rich-Text Control for Multiple Lines of Text in Dynamics 365 CE | Quick Tip

With the addition of the Rich Text Control, your Multiple Lines of Text field can make a lot more sense than before.

Standard Control

Your usual control for Multiple Lines of Text looks like this

Rich Text Control

Now, you can turn this into a Rich Text Editor
Here’s how you do it –

  1. Go to the Multiple Lines of Text field, in this case, Description field.
    select the inner control and click on Properties


  2. Now, look for Controls tab and click on Add Control as shown below

  3. Look for Rich Text Editor Control

  4. Make sure you select the new Control on all formats (or wherever you want to apply)

  5. Once you apply changes and publish, the new Control will be available for you to use.


Hope this was useful. Here are some more Dynamic 365 posts which you might want to check –

  1. Ribbon button visibility based on a field value in Dynamics 365 | Ribbon Workbench
  2. Get GUID of the current View in Dynamics 365 CRM JS from ribbon button | Ribbon Workbench
  3. Make On-Demand Flow to show up in Dynamics 365 | Power Automate
  4. Find deprecated JS code used in your Dynamics 365 environment | Dynamics 365 v9 JS Validator tool | XrmToolBox
  5. Remove ‘This Email has been blocked due to potentially harmful content.’ message in Dynamics 365 Emails | OrgDbSettings utility
  6. Track and Set Regarding are disabled for Appointments in Dynamics 365 App For Outlook message | Demystified
  7. Mailbox Alerts Hide/Show behavior in Dynamics 365 CRM
  8. Dynamics 365 App For Outlook missing on SiteMap in CRM? Use shortcut link [Quick Tip]
  9. Pass Execution Context to JS Script function as a parameter from a Ribbon button in Dynamics 365 | Ribbon Workbench
  10. Find Created On date of solution components in Solution Layers | Dynamics 365 [Quick Tip]

Thank you!

Entity Icon for entities on Unified Interface | Quick Tip

Now, Unified Interface being the only interface we have to work on in Dynamics 365 CRM, Here’s a quick tip on how and where you can set the Entity Icon for the Unified Interface.

Default Icons

One each entity, Custom or otherwise, here’s where you can set the Icon.

  1. Let’s say Commissions is a custom entity which has a default Icon.


  2. This is how it appears in the Unified Interface for any custom entity which doesn’t have any Icon set.


  3. Now, let’s look at how we can set the entity icons.

Set Icons for Entity

  1. Firstly, you need to create a Web Resource of type SVG Icon.

  2. Select the entity you want to set the Icon to in the Unified Interface. Let’s say Commission entity shows the Default Icon. Select the entity and look for Update Icons on the Solution.

  3. When you click on Update Icon, you’ll need to go to the Unified Interface.


  4. Now, in the New Icon field, you’ll have to select the Name of the SVG Icon from Step #1 above, i.e. cf_commission in this case.


  5. Select OK and Publish changes.

  6. And you’ll find the Icon is now updated for the entity entirely wherever it’ll be used on the Unified Interface. Since the Classic UI has been ruled out, we don’t need to update the classic Icons anymore.

Here are some Dynamics 365 related posts which you might need to check out –

  1. Find deprecated JS code used in your Dynamics 365 environment | Dynamics 365 v9 JS Validator tool | XrmToolBox
  2. Make On-Demand Flow to show up in Dynamics 365 | Power Automate
  3. Track and Set Regarding are disabled for Appointments in Dynamics 365 App For Outlook message | Demystified
  4. Cancelled Bookings Imported in Time Entries in Dynamics 365 PSA issue | [Quick Tip]
  5. Remove ‘This Email has been blocked due to potentially harmful content.’ message in Dynamics 365 Emails | OrgDbSettings utility
  6. Get GUID of the current View in Dynamics 365 CRM JS from ribbon button | Ribbon Workbench
  7. Get Dynamics 365 field metadata in a Canvas App using DataSourceInfo function | Common Data Service
  8. Dynamics 365 App For Outlook missing on SiteMap in CRM? Use shortcut link [Quick Tip]
  9. Debug Ribbon button customization using Command Checker in Dynamics 365 CE Unified Interface
  10. Pass Execution Context to JS Script function as a parameter from a Ribbon button in Dynamics 365 | Ribbon Workbench

Thank you!!

Remove ‘This Email has been blocked due to potentially harmful content.’ message in Dynamics 365 Emails | OrgDbSettings utility

It’s annoying to see this message on every email you Track in Dynamics 365 and just how it takes all the critical space on your timeline instead of showing you the actual email message.


Let’s look at how we can disable it using OrgDbSettings tool.

Note: I wouldn’t recommended to do these changes since we are looking to by-pass security flags dictated by Microsoft for your Org. However, if you really need to so, make sure you’ve backed up your Org before proceeding.

OrgDbSettings Editor Tool [Managed Solution]

You can download OrgDbSettings Managed Solution Utility from here – https://github.com/seanmcne/OrgDbOrgSettings

The link highlighted above is where the Releases are: https://github.com/seanmcne/OrgDbOrgSettings/releases

Once you download the Managed Solution, import it in your Org

  1. Once Imported in Dynamics, it appears like this in Solutions. Open it up.


  2. In the solution, look for SecuritySettingForEmail. Click once on the row to reveal the Description at the bottom, you’ll see the legends of what each value means.
    It’s defaulted to 1, meaning, you’ll see the warning which is what we want to hide.


  3. Next, double click on the Row and on the 1 which is the Default value as shown below.

  4. It’ll open up a Dialog to set your value of choice. In our case, we can to hide it, so I’ll put the value 3 and click on Update as shown below.

  5. It’ll update in a few seconds and you can refresh and see, the warning will be gone.



Hope this is helpful! Here are some more Dynamics 365 CE related posts you might want to check –

  1. Get GUID of the current View in Dynamics 365 CRM JS from ribbon button | Ribbon Workbench
  2. Get Dynamics 365 field metadata in a Canvas App using DataSourceInfo function | Common Data Service
  3. Dynamics 365 App For Outlook missing on SiteMap in CRM? Use shortcut link [Quick Tip]
  4. Pass Execution Context to JS Script function as a parameter from a Ribbon button in Dynamics 365 | Ribbon Workbench
  5. Find Created On date of solution components in Solution Layers | Dynamics 365 [Quick Tip]
  6. Import lookup referencing records together in Dynamics 365 CRM | [Linking related entity data during Excel Import]
  7. Add multiple Opportunity Products at once in Dynamics 365 Sales | Enhanced Experience [Preview]
  8. Mailbox Alerts Hide/Show behavior in Dynamics 365 CRM
  9. Excel Importing Notes (Annotation) entity in Dynamics 365 CRM
  10. Dynamics 365 PSA v2 to v3 Upgrade failed? Here’s what to do.

Thank you!!

Dynamics 365 App For Outlook missing on SiteMap in CRM? Use shortcut link [Quick Tip]

If you are using an older Dynamics 365 online/on-premise, you might likely be missing seeing the Dynamics 365 App For Outlook because it wasn’t originally added to SiteMap and you might not have added.

Use Shortcut provided by Microsoft Support

  1. Let’s say your Organization URL is https://<org&gt;.crm.dynamics.com/
    Then, append the below link to the Organization URL to make it look like this
    https://<org>.crm.dynamics.com/tools/appsforcrm/AppForOutlookAdminSettings.aspx

    And this will open up the Dynamics 365 App For Outlook

  2. You can also add it permanently to your SiteMap by following this Microsoft Support article from which I picked the link for you –
    https://support.microsoft.com/en-in/help/4339287/dynamics-365-app-for-outlook-missing-from-dynamics-365-navigation

    One a side note, Dynamics 365 App For Outlook is also supported for D365 on-prem. Follow this Microsoft article to know more – https://cloudblogs.microsoft.com/dynamics365/no-audience/2016/12/13/dynamics-365-app-for-outlook-support-matrix?WT.mc_id=DX-MVP-5003911

Hope this helps!!

Dynamics 365 PSA v2 to v3 Upgrade failed? Here’s what to do.

This is a little tricky upgrade from PSA v2 to PSA v3. I’m sure by this time of the year, most of you must have upgraded and this post by me comes a little late than it should.

Here’s my experience and what help from Microsoft Support I needed to complete the Upgrade successfully.

So usually, this is what you expect when you initiate the upgrade process. You go to the Instance Picker from Dynamics 365 Admin Center.
upgradeButton

And you can see that you are on PSA v2.4.x version and the New version available is 3.10.x. When you kick off, it starts running
upgradeInProgress
But, it fails like this.
installFailed

Let’s take a stab at it!

I usually prefer to go with the old school classic Instance Picker, if you want to have a quick access to it, check this post – D365 Admin Center: Instance Picker Link

Solution Health Hub

Note: Please be aware that below mentioned steps that involve Project Service & Project Service Upgrade Rule Set can only be provisioned by Microsoft Support and we need to create a Support Request with Microsoft for them to provide this Rule Set. These comes in a Managed Solution Microsoft Support installs from their end into your environment.

  1. Assuming Microsoft Support has enabled this Rule Set for your organization, you can go to Solution Health Hub
    createNewAnalysisJob
  2. Then, select either Project Service or Project Service Upgrade
    ruleSet
  3. It will automatically run asynchronously as and when you create it. It should display results in a few moments.
    failedValidation
    In this case, my failures were that Resource Requirement records didn’t have Hours & Resources were not filled in. Some Project Tasks didn’t have Project attached to them which resulted in corrupted PSA data according to the Rule Set and hence, the upgrade fails.
  4. Now, in my case, I cleaned this data manually. Post that, I created another Analysis Job to ensure that there are no more failures.
    passedRuleSet
    Also, there’s another Rule that isn’t mentioned here but is a reason for failure. That is – Project Name (msdyn_Subject) should NOT be Blank. Use Advanced Find to find these records and correct manually.  Please ensure this manually as it won’t appear here. 
  5. Now, there’s a workflow called as Update User Work History. It should have shown 3.3 or higher in the version to select, unfortunately, this will come once the upgrade fails 1 time.
    oldWF
  6. Now, you are all set to kick off Upgrade Once again. It will fail due to the incorrect workflow mentioned above in #5.
    installFailed
  7. Now, you can go back and check that workflow, it should have the correct version appearing (due to the partial upgrade that happened in #6 above, which eventually failed)
    updateUserWorkHours
    Set this to 3.3 and Activate the workflow again.
  8. Now, trigger the Update to PSA v3 one more time. And this time it should go through correctly.
    installedPlease note, due to constant upgrades in the platform/PSA, there could still be some undetected issues which could result in failure. Hence, I tried to put what I experienced in general.

    Post this, also ensure that all SDK Message Process Steps and related Workflows related to PSA are enabled.

In case you are also looking to find out about dependencies about failed Solution Upgrades, you can check this post too – Check Managed Solution failures in Solution History in D365 CE

Hope this helps!