Posted on 1/19/2018 1:15:00 PM by Levin, Aric

Business Solutions  Development  Dynamics 365 

In this third post of the series, we will review the changes between the properties and methods of the control based on the getControls Collection or the Xrm.Page.getControl method. The tables below will show the base methods of the control, as well as specific method for specific control types.

Xrm.Page.getControl

The following table show the most commonly used properties and methods in the Dynamics CRM Xrm.Page.getControl and Xrm.Page.data.entity.control classes, and the method calls in Dynamics 365 v9.

Dynamics CRM Client APIDynamics 365 v9 Client API
Xrm.Page.getControl(attr).getControlTypeformContext.getControl(attr).getControlType
Xrm.Page.getControl(attr).getAttributesformContext.getControl(attr).getAttribute
Xrm.Page.getControl(attr).getDisabledformContext.getControl(attr).getDisabled
Xrm.Page.getControl(attr).getLabelformContext.getControl(attr).getLabel
Xrm.Page.getControl(attr).getNameformContext.getControl(attr).getName
Xrm.Page.getControl(attr).getParentformContext.getControl(attr).getParent
Xrm.Page.getControl(attr).setDisabledformContext.getControl(attr).setDisabled
Xrm.Page.getControl(attr).setFocusformContext.getControl(attr).setFocus
Xrm.Page.getControl(attr).setLabelformContext.getControl(attr).setLabel
Xrm.Page.getControl(attr).setVisibleformContext.getControl(attr).setVisible
Xrm.Page.getControl(attr).setNotificationformContext.getControl(attr).setNotification
Xrm.Page.getControl(attr).clearNotificationformContext.getControl(attr).clearNotification

 

The next table will show additional properties and methods of the Xrm.Page.getAttribute and Xrm.Page.data.entity.attribute classes, that are specific to particular data types.

Attribute TypeDynamics CRM Client APIDynamics 365 v9 Client API
DateTimeXrm.Page.getControl(attr).getShowTimeformContext.getControl(attr).getShowTime
DateTimeXrm.Page.getControl(attr).setShowTimeformContext.getControl(attr).setShowTime
LookupXrm.Page.getControl(attr).addCustomFilterformContext.getControl(attr).addCustomFilter
LookupXrm.Page.getControl(attr).addCustomViewformContext.getControl(attr).addCustomView
LookupXrm.Page.getControl(attr).addPreSearchformContext.getControl(attr).addPreSearch
LookupXrm.Page.getControl(attr).getDefaultViewformContext.getControl(attr).getDefaultView
LookupXrm.Page.getControl(attr).removePreSearchformContext.getControl(attr).removePreSearch
LookupXrm.Page.getControl(attr).setDefaultViewformContext.getControl(attr).setDefaultView
OptionSetXrm.Page.getControl(attr).addOptionformContext.getControl(attr).addOption
OptionSetXrm.Page.getControl(attr).clearOptionsformContext.getControl(attr).clearOptions
OptionSetXrm.Page.getControl(attr).removeOptionformContext.getControl(attr).removeOption
Web Resouce/IFrameXrm.Page.getControl(attr).getDataformContext.getControl(attr).getData
Web Resouce/IFrameXrm.Page.getControl(attr).getInitialUrlformContext.getControl(attr).getInitialUrl
Web Resouce/IFrameXrm.Page.getControl(attr).getObjectformContext.getControl(attr).getObject
Web Resouce/IFrameXrm.Page.getControl(attr).getSrcformContext.getControl(attr).getSrc
Web Resouce/IFrameXrm.Page.getControl(attr).setDataformContext.getControl(attr).setData
Web Resouce/IFrameXrm.Page.getControl(attr).setSrcformContext.getControl(attr).setSrc

Click here to access the reference to the formContext.getControl properties and methods in Dynamics 365 CE. 

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Navigate to original post to enter comments