Personalized Community is here!
Quickly customize your community to find the content you seek.
Check out the latest Sales updates!Learn about the key capabilities and features of Dynamics 365 Sales and experience some of the new features.
Download overview guide | Watch Sales video
2020 Release Wave 2Discover the latest updates and new features to Dynamics 365 planned through March 2021.
Release overview guides and videos Release Plan | Preview 2020 Release Wave 2 TimelineWatch the 2020 Release Wave 2 virtual launch event
Ace your Dynamics 365 deployment with packaged services delivered by expert consultants. | Explore service offerings
Connect with the ISV success team on the latest roadmap, developer tool for AppSource certification, and ISV community engagements | ISV self-service portal
The FastTrack program is designed to help you accelerate your Dynamics 365 deployment with confidence.
FastTrack Program | Finance TechTalks | Customer Engagement TechTalks | Upcoming TechTalks
The actual scenario is I have an entity for data mapping with an account, we had given the privilege to the user to create a new attribute
depends upon the data they are importing
as well I have two fields in the account if the two filed contains data I want to make read-only for all the attributes are related data mapping entity.
Since you have mapped some fields between your custom entity and account, you should know which fieds are mapped.
And there should be a relationship between custom entity and account.
So we chould resolve this requirement in this way.
1.Check if the two fields contain data when onloading the account form.
As you konw using "formContext.data.entity.attributes.get()" will get all the fields on the form, and if you want to get a special field's value, you could use the following code.
We could use "find" method to find the special field we need with its field name.
But there is a better way to get the field on the form, using "formContext.getAttribute()" could get the field directly and this method could also imporve the peformance cause it doesn't need to get all the fields on the form.
2.Get the mapped field value in custom entity by web api.
For example, if custom data entity has an 1:N relationship with account, so there should be a custom entity lookup field on the account entity.
We could use the following code to get the related entity data by web api.
3.Compare the fields value and disable/enable the fields.
Hope it helps.
Thanks its worked I used web Api retrieve multiple I was comparing more than one
Business Applications communities