Бөлісу құралы:


Xrm.Page.ui tab (client-side reference)

 

Applies To: Dynamics 365 (online), Dynamics 365 (on-premises), Dynamics CRM 2016, Dynamics CRM Online

A tab is a group of sections on a page. It contains methods to manipulate tabs as well as access to sections within the tab through the sections collection.

Properties and Methods

  • DisplayState
    Use the getDisplayState and setDisplayState methods to determine whether the tab is collapsed or to collapse and expand the tab.

  • getName
    Method to get the name of the tab.

  • getParent
    Method to return the Xrm.Page.ui (client-side reference) object that is the parent to all tabs.

  • Label
    Use the getLabel and setLabel methods to determine the label for the tab or to hide and show the tab label.

  • sections
    A collection of sections within the tab.

  • setFocus
    Method to set focus on a tab.

  • Visible
    Use the getVisible and setVisible methods to determine the tab is visible or to hide and show the tab.

DisplayState

Use the getDisplayState and setDisplayState methods to determine whether the tab is collapsed or to collapse and expand the tab.

getDisplayState

Returns a value that indicates whether the tab is collapsed or expanded.

tabObj.getDisplayState()
  • Return Value
    Type: String

    Possible values:

    • expanded

    • collapsed

  • Remarks
    For Dynamics 365 mobile clients (phones and tablets), this method will always return expanded because tabs cannot be collapsed. This method isn't supported for the interactive service hub.

setDisplayState

Sets the tab to be collapsed or expanded.

tabObj.setDisplayState(string)
  • Arguments
    String

    Valid argument values:

    • expanded

    • collapsed

  • Remarks
    This method isn't supported for Dynamics 365 mobile clients (phones and tablets) and the interactive service hub because tabs cannot be collapsed.

getName

Returns the name of the tab.

tabObj.getName()
  • Return Value
    Type: String

getParent

Returns the Xrm.Page.ui (client-side reference) object.

tabObj.getParent()
  • Return Value
    Type: Object

Label

Use the getLabel and setLabel methods to determine the label for the tab or to hide and show the tab label.

getLabel

Returns the tab label.

tabObj.getLabel()
  • Return Value
    Type: String

setLabel

Sets the label for the tab.

tabObj.setLabel(String)
  • Arguments
    String

sections

The sections collection provides access to sections within the tab. See Collections (client-side reference) for information about methods to access the sections in the collection. See Xrm.Page.ui section (client-side reference) for information about the properties and methods of the section objects in the collection.

setFocus

Sets the focus on the tab.

tabObj.setFocus()

Visible

Use the getVisible and setVisible methods to determine the tab is visible or to hide and show the tab.

Note

Another way to hide a tab is to hide all the sections within it. If all the sections within a tab are not visible, the tab will not be visible.

getVisible

Returns a value that indicates whether the tab is visible.

tabObj.getVisible()
  • Return Value
    Type: Boolean

setVisible

Sets a value that indicates whether the control is visible.

tabObj.setVisible(boolean);
  • Arguments
    Boolean

See Also

Client-side programming reference
Form scripting quick reference
Xrm.Page.ui (client-side reference)
Write code for Microsoft Dynamics 365 forms
Use the Xrm.Page object model

Microsoft Dynamics 365

© 2016 Microsoft. All rights reserved. Copyright