New to Telerik UI for ASP.NET AJAXStart a free 30-day trial

RadToolBarItem Object

The RadToolBarButton, RadToolBarDropDown, and RadToolBarSplitButton objects share most of the same methods.

Common RadToolBarItem methods

The following table lists the most important of the common RadToolBarItem client-side object methods:

NameParametersReturn TypeDescription
findControlStringObjectReturns the client-side object of the Control with the specified ID nested in the Item's Template. The ID passed as an argument to the function MUST be the ID attribute of the nested Control.
get_toolBarnoneRadToolBarReturns the toolbar to which the item belongs.
enablenonenoneEnables the toolbar item.
disablenonenonedisables the toolbar item.
get_enablednonebooleanReturns true if the item is enabled.
clicknonenoneCauses server-side button click event to occur
set_enabledbooleannoneSets whether the item is enabled.
get_isEnablednonebooleanReturns true if both the item and the toolbar are enabled. If one of them is disabled, get_isEnabled() will return false.
focusnonenoneMoves focus to the item.
blurnonenoneMoves focus off the item to the next element in the tab order.
get_focusednonebooleanReturns true if the item has focus.
get_textnonestringReturns the text of the item.
set_textstringnoneSets the text of the item.
get_valuenonestringReturns the value of the item.
set_valuestringnoneSets the value of the item.
get_indexnoneintegerReturns the index of the item in the toolbar or drop-down list.
get_isFirstnonebooleanReturns whether the item has index 0.
get_isLastnonebooleanReturns whether the item is the last in the toolbar or drop-down list.
get_nextSiblingnoneRadToolBarItemReturns the next item in the toolbar or drop-down list.
get_previousSiblingnoneRadToolBarItemReturns the previous item in the toolbar or drop-down list.
get_toolTipnonestringReturns the text of the item's tool tip.
set_toolTipstringnoneSets the text of the item's tool tip.
get_attributesnoneAttributesReturns the collection of custom attributes defined for the item.
get_elementnoneHTML elementGets the DOM element for the item.
get_imageElementnoneHTML elementGets the DOM element for the image of the item.
get_textElementnoneHTML elementGets the DOM element for the text of the item.
get_innerWrapElementnoneHTML elementGets the DOM element for the innermost SPAN that wraps the item.
get_middleWrapElementnoneHTML elementGets the DOM element for the middle SPAN that wraps the item.
get_outerWrapElementnoneHTML elementGets the DOM element for the outermost SPAN that wraps the item.
shownonenoneShows the toolbar item. If you are using the responsive features, make sure to call the toolbar's .repaint() method afterwards.
hidenonenoneHides the toolbar item. If you are using the responsive features, make sure to call the toolbar's .repaint() method afterwards.
get_clickednonebooleanTrue if the item is clicked.
get_focusednonebooleanTrue if the item is focused.
get_hoverednonebooleanTrue if the item is hovered.
get_levelnoneintegerGets the level of the item. Buttons and child items of a drop down button have 0 level. Child items of a split button are with level 1.
get_navigateUrlnonestringReturns the NavigateUrl of the item
set_navigateUrlstringnoneSets the NavigateUrl of the item
get_overFlownoneintegerReturns the Overflow of the item where Telerik.Web.UI.ToolBarOverflow.Auto = 0; Telerik.Web.UI.ToolBarOverflow.Always = 1; Telerik.Web.UI.ToolBarOverflow.Never = 2;.
set_overFlowintegernoneSets the Overflow of the item where Telerik.Web.UI.ToolBarOverflow.Auto = 0; Telerik.Web.UI.ToolBarOverflow.Always = 1; Telerik.Web.UI.ToolBarOverflow.Never = 2;

RadToolBarButton methods

In addition to the common methods listed above, RadToolBarButton supports the following methods:

NameParametersReturn TypeDescription
checknonenoneSets the checked property to true .
unChecknonenoneSets the checked property to false .
togglenonenoneToggles the checked property.
get_checkednonebooleanReturns the value of the checked property.
get_isCheckednonebooleanSame as get_checked.
get_commandNamenonestringReturns the name of the command associated with the item.
set_commandNamestringnoneSets the CommandName of the item.
get_commandArgumentnonestringReturns the value of the CommandArgument property.
set_commandArgumentstringnoneSets the CommandArgument of the item.
get_isSeparatornonebooleanReturns whether the item is a separator.
get_groupnonestringGets the name of the group to which the item belongs.
set_groupstringnoneSets the name of the group to which the item belongs.
get_enableDefaultButtonnonebooleanReturns true if EnabledDefaultButton is enabled.
set_enableDefaultButtonbooleannoneEnables/Disables the EnabledDefaultButton mechanism.
set_imageUrlstringnoneSets the URL for the image.
get_imageUrlnonestringReturns the URL of the image.
set_hoveredImageUrlstringnoneSets the URL for the hovered-state image.
get_hoveredImageUrlnonestringReturns the URL of the hovered-state image.
getDefaultButtonnoneRadToolBarButtonReturns the default button.
get_defaultButtonIndexnoneIntReturns the index of the Default Button.
set_defaultButtonIndexIntnoneSets the index of the Default Button.

RadToolBarDropDown methods

RadToolBarDropDown supports the following additional methods:

NameParametersReturn TypeDescription
get_buttonsnoneRadToolBarButtonCollectionReturns the collection of items in the drop-down list (if it exists).
get_dropDownElementnoneHTML element
get_animationContainernoneHTML elementReturns the DOM element for the animation container of the item's drop-down list.
showDropDownnonenoneOpens the drop-down list.
hideDropDownnonenoneCloses the drop-down list.

RadToolBarSplitButton methods

RadToolBarSplitButton supports the following additional methods:

NameParametersReturn TypeDescription
get_buttonsnoneRadToolBarButtonCollectionReturns the collection of items in the drop-down list (if it exists).
get_commandNamenonestringReturns the name of the command associated with the item.
get_commandArgumentnonestringReturns the value of the CommandArgument property.
get_dropDownElementnoneHTML elementReturns the DOM element for the item's drop-down list.
get_animationContainernoneHTML elementReturns the DOM element for the animation container of the item's drop-down list.
set_imageUrlstringnoneSets the URL for the image.
get_imageUrlnonestringReturns the URL of the image.
set_hoveredImageUrlstringnoneSets the URL for the hovered-state image.
get_hoveredImageUrlnonestringReturns the URL of the hovered-state image.
showDropDownnonenoneOpens the drop-down list.
hideDropDownnonenoneCloses the drop-down list.