Sitemap

Wednesday, April 30, 2014

Picklist length in MS CRM 2011 Javascript

1. To get length of picklist options we should use below line of code in javaScript


var length=Xrm.Page.getAttribute("field Name").getOptions().length;

2. To get pickpist item of an index some x use below code


var optionSetXrm=Xrm.Page.getAttribute("field Name");

for(var i=0; i<optionSetXrm.getOptions().length;i++)
{

var optionSetText= optionSetXrm.getOptions()[i].text;
var optionSetValue= optionSetXrm.getOptions()[i].value;

}


You may like below posts

date and time field behavior in MS CRM

Upsert in MSCRM

Locking mechanism in MS CRM

Ticker Symbol Field in MS CRM

Themes in MS CRM

Enable Tracing in MS CRM

Improving MS CRM Performance

Performance Center in MS CRM 2013

Calculated Field in Dynamics CRM 2015

IME Mode in MS CRM

No comments:

Post a Comment