Using Custom JavaScript field on Entity List to add JavaScript in Portal in Dynamics 365

Suppose we have added an Entity List on Portal to display Contact information to the portal.

https://nishantrana.me/2017/02/02/using-entity-list-to-show-crm-data-in-portal-in-dynamics-365/

Now we want to add some JavaScript to it. For this we can use the Custom JavaScript field in Options tab of Entity List.


$(document).ready(function () {

$("#EntityListControl").on("loaded", function () {

$('#EntityListControl td').filter(function () {
return this.textContent === "SYSTEM"
}).css("color", "red");

});
});

We can make use of jQuery for this. The above code selects the TD with text System and highlights it with red font colour.

Hope it helps..


Author: Nishant Rana

I love working in and sharing everything about Microsoft.NET technology !

2 thoughts on “Using Custom JavaScript field on Entity List to add JavaScript in Portal in Dynamics 365”

Share your thoughts

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s