Hi Everyone
Today I have created an entity and was checking the configuration to rename the form name. While doing this, have found a setting to hide "Related" Tab on UCI. I still remember the discussions with Customers on explaining this Related tab saying we don't have control on it :).
Related tab is good to have when an entity has relationships with other entities but sometimes you might not need it as entity might be stand alone or a child entity. Here is the setting for hiding the same.
Open the Form Properties of the entity --> Display Tab --> Un-check "Show navigation items", Save and Publish.
Hope this helps.
--
Happy 365'ing
Gopinath
Hi Everyone,
Today I was checking System Settings to configure something and I found a setting to enable or disable Rich Text Editor for Notes on Timeline. Somehow I feel we don't need a setting for this, who wants disable this wonderful feature. However, if anyone is looking to disable to Rich Text Editor check this out.
Hope this helps.
--
Happy 365'ing
Gopinath
Hi Everyone,
Certainly, everyone Dynamics 365 CE Consultant/Architect must have started importing the solutions and went for dinner, lunch, break or checked the mobile thinking the solution import would take some time. After they come back, the import might be still going on and at that time everyone would be eager to check what exactly the status of the import.
Also sometimes, knowingly or unknowingly you might cancelled/closed import wizard thinking let's start the import again and when you try again the system must have shown a message saying "The import is in progress." and you never know when it completes.
We have a solution for this, we can check the progress of the solution from Import Jobs. Open Advance Find and look for import Jobs, add a filter to show the records created on from last one or two hours (I normally apply the filter on Created on, if you want to get the results and sort on CreatedOn column). You will see the results showing percentage.
Hope this helps.
--
Happy 365'ing
Gopinath
Hi Everyone,
The most awaiting feature Modal popups are available in Dynamics 365 now and made our lives easier for many things, we are getting many requirements to open the records as a popup where we have control on the parent record and hence not loosing the changes.
One of the requirement I heard today was opening the record as popup from Subgrid. Initially we thought there is no way but after quick check we are done with the job with the help of the Editable Grids.
Let's say there is a subgrid on Account as Contact and whenever user selects the record we can make use NavigateTo function and open the selected record as a popup. We have to put below code on the RecordSelect event of the subgrid.
function onRecordSelect(executionContext) {
var selectedRecord = executionContext.getFormContext().data.entity;
var Id = selectedRecord.getId();
var entityName = selectedRecord.getEntityName();
var pageInput = {
pageType: "entityrecord",
entityName: entityName,
entityId: Id
};
var navigationOptions = {
target: 2,
height: { value: 70, unit: "%" },
width: { value: 70, unit: "%" },
position: 1
};
Xrm.Navigation.navigateTo(pageInput, navigationOptions).then(
function success() { },
function error() { }
);
}
Hope this helps.
--
Happy 365'ing
Gopinath
Hi Everyone,
Today one of the Developer in my team was stuck with one issue and the issue was about validating users security roles and allowing the user to perform some operation. User was associated with only 2 security roles and the below line of code was giving 4 GUIDs. When we checked the code, whatever he was saying was correct. After few mins, we came to know that this line gets the roles of the Teams where user is associated along with roles that were given to the users.
Xrm.Utility.getGlobalContext().userSettings.securityRoles
Hope this helps.
--
Happy 365'ing
Gopinath
Hi Everyone,
Today I got some strange requirement that to open the record by setting up to specific Business Process Flow on UI when clicked on the lookup from the child form.
We need to understand multiple new things from doing this.
1) addOnLookupTagClick event - Refer this to understand more about. By this event, we can prevent the default behavior of the click event on lookup.
2) OpenForm - As we all know that we have to use Xrm.Navigation.openForm for opening the records and fortunately we can pass the ProcessId and ProcessInstanceId in the entityFormOptions. In case, if you want to open the record in a specific stage, We have pass stageID.
Here is the piece of code for the same and I have called this code on the load event.
function onLoadOfOpportunity(executionContext) {
var formContext = executionContext.getFormContext();
formContext.getControl('new_parentopportunity').addOnLookupTagClick(function (e) {
e.getEventArgs().preventDefault(); // disables the default behaviour of opening the record
// Get the lookup record
var lookupRecord = e.getEventArgs().getTagValue();
// Xrm.Navigation.openForm(entityFormOptions, formParameters).then(successCallback, errorCallback);
var entityFormOptions = {};
entityFormOptions["entityName"] = "opportunity";
entityFormOptions["entityId"] = lookupRecord.id;
entityFormOptions["processId"] = "EC985A4F-E5E2-489F-A13D-4AFBECD6A769";
entityFormOptions["processInstanceId"] = "F532CF05-8B83-EA11-A811-000D3A3E14C7";
// Open the form.
Xrm.Navigation.openForm(entityFormOptions).then(
function (success) {
console.log(success);
},
function (error) {
console.log(error);
});
});
}
When I open the record from the HomePage grid. You see the process as "Opportunity Sales Process".
The same record if open from the lookup, you see "Second Business Process Flow"
Hope this helps.
--
Happy 365'ing
Gopinath
Hi Everyone,
Today I was testing something on 2020 Wave 1 Release version of Dynamics 365 and you know, I am able to see the Status of the activities on the timeline. It was there on some older versions and suddenly disappeared. Not sure what happened and it was very hard to find what are the pending activities to take an action without status.
And, now it is back. Thanks for fixing it.
Hope this helps.
--
Happy 365'ing
Gopinath
Hi Everyone,
I was going through the solution components today and found Environment Variables when clicked on New button after opening the solution.
Explored little bit about it and here are the takeaways.
From ages, we are using custom entities for storing configurations which might differ from environment to environment and using them in Plugins, Workflows, JavaScript and now in Flows and Powerapps as well.
When should we use Environment Variables?
- When an input parameter needs to change across environments and should not be hard-coded. For example, a URL that points to a different resource in development and production environments.
- If you’re building a solution where your customer is required to provide an input value.
- When multiple components require the same input. Instead of entering that input multiple times, reference the environment variable. If the value needs to change, make an update in one place.
- If you need to update configuration values without modifying code or if the person managing the configuration is not familiar with coding. For example, a plugin that references a blob store location could be updating without directly modifying the plugin.
When shouldn’t we use Environment variables?
- To transport secure data such as passwords or other secrets.
- If several values are required for one definition.
Let's go ahead and create an Environment Variable to understand it more.
It can handle below datatypes.
Up on creating 'Environment variable', a new record gets added to both OOB 'Environment Variable Definition' entity and 'Environment Variable Values' entities.
'Environment Variable Values' is child to the 'Environment Variable Definition' entity.
What is Default Value?
This field is part of the Environment variable definition entity is not required. Set a default value for the value to be used in production or when the values should remain the same across different environments. The Environment variable definition will be represented in the customizations.xml in your solution file
What is Current Value?
This field is optional and is a part of the “Environment variable value” entity. Also known as a current value or override value. Set this when you’d like to override the default value in your current environment. Remove the value from your solution if you don’t want this value used in the next environment. While it is typically unhealthy to modify solution components in production environments, you may enter a current value in the production environment without introducing unhealthy behaviors to the consuming component or the Environment variable definition. Note: a 1:1 relationship is currently enforced between the Environment variable definition and the Environment variable value. A value also cannot exist without a definition.
Why is there a default value and a value? This allows you to service the definition and default value separately from the current value. It also allows us to extend the functionality in the future to support multiple values scoped to a specific run time context. A separate JSON file added to your solution file that stores the values.
Note: The above is only a recommendation on how to use default values and values. If using both, you will need to handle the logic to determine which value should be used.
To test this, I have created a flow and retrieved Environment Variable Definition by filtering the SchemaName as below.
In the above example, I applied query on "Environment Variable Definition" entity and if you have current values, you have to add one more List Records step in the Loop to query "Environemnt Varialble Value" and in the Filter query, enter _environmentvariabledefinitionid_value eq and add the Environment Variable Definition from the dynamic content list.
We can move these from one environment to other using Solution Import. When we export the solution, you will see a separate JSON added in the solution.
Note: This is still under preview, please check this link for more information.
Hope this helps.
--
Happy 365'ing
Gopinath
Hi Everyone,
Today I was doing some testing, observed a filter just beside Search box on the Grid and when I clicked it has opened as a popup.
Played little bit with that and you know it works like a charm. It allows us to build simple to complex filters without even opening Advance Find.
You can add more filters by selecting a column to filter on, then choosing an operator and selecting a value. The set of operators available on a column adjust intelligently according to the data type of the column to help you stay productive.
Individual conditions can be grouped and nested to create expressions to apply the right lens to your dataset.
Once the filters are applied, you can easily clear them using the Clear filters button, which resets the view back to its original definition. The asterisk next to the view name indicates unsaved changes, which can be easily saved into a new personal view that is always available in the view selector.
Hope this helps.
--
Happy 365'ing
Gopinath
Hi Everyone,
I was exploring Microsoft Flows today and was trying to create and update records with different data types. While testing observed that Multi Select values are getting overridden and it is understandable as well. However, we might have to take care it while implementing.
For example, if I am updating a record for which Multi select value is already selected and I would like to select some more. In this scenario if you set the field to consider the new value, the system will remove existing values and updates the record with the value whatever that was set by us.
Lead - My First Lead has values as Printers for Product Interest.
In flow, I am updating that to Laptops and Mobiles.
After I ran the flow, the previous value "Printers" is no where selected on the record.
To fix this issue, we have to retrieve the record before we update and set Multi-select field with the concatenation of existing values and new values.
Set the existing value in the variable.
Use Concat function while setting the field. Here the expression which I have used.
Syntax - concat('767070000',',','767070001',',',variables('ProductInterestExistingValues'))Here is the updated record.
Hope this helps.
--
Happy 365'ing
Gopinath
Hi Everyone,
Today I was going through Sales Hub and enabled Sales Insights to understand it more. As part of the Dynamics 365 Sales offering, only some of the basic features are available for free. Somehow, I feel Notes Analysis is a useful feature. It requires you to have a Sales Insight license. You can enable a free trial of this app though, to check how it works.
Enable Sales Insights in Dynamics 365
1) Navigate to Sales Hub and select Sales Insight Settings.
2) Select Try Sales Insights to enable and set up the sales insight subscription.
3) It takes few minutes to install and once the installation is completed, you will see the screen as below. Click on Go to Configuration or Navigate to Sales Insight Settings.
4) Enable Notes Analysis by click on Set up button. That's it. Notes analysis has been enabled on your instance.
Before we go into reality, let's try to understand what exactly Notes analysis does for us.
"Notes analysis provides you with suggestions for actions based on customer-related activities. When you create an activity, such as appointment, phone call, task, note, post, or custom activities, the notes analysis feature analyzes the descriptions provided in these activities and gives you intelligent suggestions. With these suggestions, you can take actions, such as creating a meeting request and adding a contact."
Let's check what exactly it does in reality.
I just opened an existing Account and entered a Notes with Subject and Description as below and the system has changed the description to link and on click of that we see a popup of the card to take an action.
Subject - Next week
Description - Le'ts have a call next week.
Subject - Meeting tomorrow
Description - Let's have a meeting tomorrow 4 PM and close the deal.
On click on Edit and Create button in the card, the system opens a Quick Create form for Phone call. There are two bugs in this, Subject has div tags and Regarding is showing No name. Hoping Microsoft fixes them soon.
Hope this helps.
--
Happy 365'ing
Gopinath
Hi Everyone,
Sharing an App to the users is much more easier than before with PowerApps new UI. Previously, it was a lengthy process which required several steps. This has been streamlined into a single panel now.
As we all know that Sharing a Model-Driven app requires two steps.
1) Associate one or more security roles with the App.
2) Assign the Security role to users.
Here are the steps to be followed to share the app with users.
1) Visit https://make.powerapps.com
2) Select a model-driven app and click Share.
3) Select the app then choose a security role from the list.
4) Search for a user.
5) Select the user then select a role from the list.
6) Click Share.
Hope this helps.
--
Happy 365'ing
Gopinath