Description
Inserts a category as the last item in the RibbonBar control.
Applies to
Syntax
controlname.InsertCategoryLast ( String Text )
controlname.InsertCategoryLast ( RibbonCategoryItem Item )
Argument |
Description |
---|---|
controlname |
The name of the RibbonBar control. |
Text |
The title of the category to be inserted. |
Item |
A category item to be inserted. |
Return value
Long.
Returns the handle of the inserted item if it succeeds and -1 if an error occurs. If any argument's value is null, returns null.
Example 1
This example inserts the "MyCategory3" category as the last category in the ribbon bar.
Long ll_Handle ll_Handle = rbb_1.InsertCategoryLast ("MyCategory3")
Example 2
This example also inserts the "MyCategory3" category as the last category in the ribbon bar. It first defines a category item with various properties (including Text, Tag etc.) and then inserts it as the last category in the ribbon bar.
Long ll_Handle RibbonCategoryItem lr_Category lr_Category.Text = "MyCategory3" lr_Category.Tag = "MyCategory3" ll_Handle = rbb_1.InsertCategoryLast (lr_Category)
See also