Getting "nbsp" on InvalidPluginExecutionException - dynamics-crm

Hi when i'm calling InvalidPluginExecutionException in a plugin i'm getting the '&nbsp' instead of spaces, this is only happening in the Connection entity.
This is dynamics on-prem (9.0.26.5)
This is the line of code:
throw new InvalidPluginExecutionException("Can't connect 2 Structures or 2 Contacts !\n");
This is the result:
Can't connect 2 Structures or 2 Contacts !If you contact support, please provide the technical details.

Related

Could not register pre-delete validatation plugin step for the Team entity in MS Dynamics CRM 2011

I want to add validation before Team entity deletion. In order to do that, I need to add Pre-validation plugin step for the Delete message and Team entity.
Nevertheless, when I'm trying to do it via the Plugin Registration Tool, I'm getting an error:
Invalid Entity Name
Invalid Primary Entity or Secondary Entity specified. Please re-enter the data.
Here is the data I'm filling in the Register New Step:
Message: Delete
Primary Entity: team
Secondary Entity: none
Run in User's Context: Calling User
Execution Order: 1
Eventing Pipeline Stage of Execution: Pre-validation
Execution Mode: Synchronous
Deployment: Server
I'm using Microsoft Dynamics CRM 2011.
I could not find any explanation for that. What I'm asking is:
What is the reason for that?
What is the intended way of applying custom validations during the deletion of the Team entity?
That's because Delete Message for Team Entity in CRM 2011 is not supported
Whereas when you look for CRM 2016 and above Team Entity does support delete Message
Summary: CRM 2011 Team Entity does not support Delete Message
It is possible to enable registering the plug-in by updating the corresponding SdkMessageFilterBase record.
Connect to your DB server.
Navigate to your %ORGANIZATION_NAME%_MSCRM DB.
Run the script:
SELECT
[dbo].[SdkMessageFilterBase].[PrimaryObjectTypeCode],
[dbo].[SdkMessageFilterBase].[CustomizationLevel],
[dbo].[SdkMessageFilterBase].[SecondaryObjectTypeCode],
[dbo].[SdkMessageFilterBase].[IsCustomProcessingStepAllowed],
[dbo].[SdkMessageFilterBase].[Availability],
[dbo].[SdkMessageFilterBase].[SdkMessageId],
[dbo].[SdkMessageFilterBase].[IsVisible]
FROM
[dbo].[SdkMessageFilterBase]
INNER JOIN [dbo].[SdkMessageBase]
ON [dbo].[SdkMessageFilterBase].[SdkMessageId] = [dbo].[SdkMessageBase].[SdkMessageId]
WHERE
[dbo].[SdkMessageBase].[Name] = 'Delete' AND
[dbo].[SdkMessageFilterBase].[PrimaryObjectTypeCode] = 9 -- Team entity code is 9
Check the result. If IsCustomProcessingStepAllowed field is set to 0, it is preventing you from registering the plug-in step.
Update IsCustomProcessingStepAllowed to 1 to be able to register custom plug-in step.
This solution worked for me.
Articles describing such solution:
Enabling plug-in for Change Business Unit and Change Manager for systemuser entity

Business Central Dynamics 365 Sales Connection Setup Error in Sync Queues for Item, Opportunity, Resource and Others

I am working on Business Central on a demo tenant. I have set up Common Data Service Connection Setup and Dynamics 365 Sales Connection Setup. When I run a initial sync in a new company made with production - setup data only the Customer, Contact, Currency and Vendor Entities sync job are being run and finished successfully(so it is written in status of the wizard and I can find new account in CRM which were previously created in Business Central). Before running the sync I removed the CRM Customer Engagement licence from the integration user and set him up in CRM as a non-interactive type of user.
The error I receive from the Item, Opportunity and Resource entity are the following:
Open record "An error occurred when communicating with Common Data
Service. Detailed description: 'Product' entity doesn't contain
attribute with Name = 'bcbi_companyid' and NameMapping = 'Logical'.
MetadataCacheDetails: ProviderType=Dynamic, StandardCache=Tru"
Open record "An error occurred when communicating with Common Data
Service. Detailed description: 'Opportunity' entity doesn't contain
attribute with Name = 'bcbi_companyid' and NameMapping = 'Logical'.
MetadataCacheDetails: ProviderType=Dynamic, StandardCache"
Open record "An error occurred when communicating with Common Data
Service. Detailed description: 'Product' entity doesn't contain
attribute with Name = 'bcbi_companyid' and NameMapping = 'Logical'.
MetadataCacheDetails: ProviderType=Dynamic, StandardCache=Tru"
Other entities in initial sync are not run and i believe that the sync stopped on those errors. I cannot finish the initial sync. After returning the licence and trying again to run the error remains and the sync is not finished. Am I missing a company property somewhere ?

Event Grid with communication with 2 microservices

We are trying to achieve event-based communication between 2 microservices
Currently we have created 2 microservices with .Net Core.
Email Service
http://xxxx.demoemailserviceapi.azurewebsites.net/swagger
Product Service
http://yyyy.azurewebsites.net/swagger
We have created Event Grid to handle the communication between them. When we try to add endpoints to eventgrid and proceed with deployment then we are getting error as follows
Deployment has failed with the following error: {"code":"Url validation","message":"The attempt to validate the provided endpoint https://xxx.azurewebsites.net/runtime/webhooks/EventGrid failed. For more details, visit https://aka.ms/esvalidation."}
How can I resolve this?
I do recommend to read the following documents:
Event Grid trigger for Azure Functions
Event Grid security and authentication
Note, that the endpoint url of the EventGridTrigger function has the format:
https://{functionappname}.azurewebsites.net/runtime/webhooks/eventgrid?functionName={functionname}&code={systemkey}

APIC 2018.210 OVA: URL format error when associating Analytics with Gateway

I am in the process of configuring the local Cloud. I have successfully registered: DataPower Gateway, Analytics and Portal services.
When I tried to associate the Analytics and Gateway services, I got this error message:
Associate Analytics has not been created!
Error validating the request body against definition
'#/components/schemas/GatewayService' analytics_service_url Does not match format 'uri'
(context: (root).analytics_service_url, line: 1, col: 26)
400
I don't find this message to be at all helpful. The Gateway urls all use ip addresses; Analytics is hostname.domain.name (FQDN) and it is the endpoint defined for analytics-client. The yaml file defines 'analytics-ingestion' as different-hostname.domain.name.
I'd be really grateful for any guidance.
Regards, John
This was caused by really poor basic GUI design.
On the Associate Analytics Service page, there is only one row (Analytics Service | Availabilty Zone). On the far left is an extremely faint circular checkbox. I hadn't spotted it so it was not selected. It works when the checkbox selected.
The Associate button should be disabled when the checkbox isn't selected. That's the poor design. It would also help if the checkbox were to be easier to spot.
John

Microsoft Dynamics CRM Online 2016: Cannot set task/phonecall statecode to 'Completed'

When using the Microsoft Dynamics CRM Online 2016 OData API, I ran into a problem
creating a task/phonecall with statecode equal to completed.
Problem Description:
create a phone call entity with statecode=1 (Completed)
statuscode=2 (Made)
same idea with task (constants defined here)
API returns an internal server error saying that:
2 is not a valid status code for state code PhoneCallState.Open on phonecall with Id cfdb5757-3666-e611-80fa-3863bb2ed1f8.
Dynamics server ignored the PhoneCallState.Completed (statecode = 1) parameter
that I passed to it.
For now, the workaround is to make a separate PATCH request to update the statecode and statuscode.
Is there a way to create a task/phonecall with completed state in one request?
I don't believe you can create a record in a completed status (statecode). So you will need to do a create call followed by an update or set state, I think that is just the way CRM works.
I believe that James's answer is correct. If you truly wanted to perform a single create, and create it as Completed, you could add two new fields to the Entity (PostCreateStatus, PostCreateState) and then create a Post Create Plugin that updates the status and state. This would be result in a single call to the server, creating the entity with the desired states and statuses.

Resources