Skip to main content

ASPxClientRibbon.GetItemByName(name) Method

Returns a ribbon item specified by its name.

Declaration

GetItemByName(
    name: string
): ASPxClientRibbonItem

Parameters

Name Type Description
name string

A string value specifying the name of the item.

Returns

Type Description
ASPxClientRibbonItem

An ASPxClientRibbonItem object that is the ribbon item with the specified name.

Remarks

A ribbon control’s client-side functionality allows individual items to be accessed programmatically. The GetItemByName method gets a client item object specified by its name. An item’s name is defined by the RibbonItemBase.Name property.

clientSpreadSheet.GetRibbon().GetItemByName('Item').SetEnabled(true);

This method searches the specified item amongst all items contained by the ribbon control. Note that if an invalid name is passed via the parameter, this method returns null.

See Also