This is a migrated thread and some comments may be shown as answers.

Need help with splitbuttonelement in ribbonbar

9 Answers 28 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
میثم
Top achievements
Rank 1
میثم asked on 13 Jan 2017, 04:21 AM

Hi

In the ribbonbar i have placed splitbuttonelement and it has several menuitems. I have problem with the value (or index) of menu item that selected by user.i need a code to learn how can i do this and what events need to use.

 Thanks.

9 Answers, 1 is accepted

Sort by
0
Dimitar
Telerik team
answered on 13 Jan 2017, 09:38 AM
Hello,

You need to use the Click event of each item in this case. An example for this is available here: Getting Started.

I hope this information is useful. Let me know if you need further assistance.

Regards,
Dimitar
Telerik by Progress
Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
0
میثم
Top achievements
Rank 1
answered on 13 Jan 2017, 11:40 AM
Thanks. But in the related link there wasn't any usefull code for selecting menuitems of splitbutton in click event. 
0
Dimitar
Telerik team
answered on 13 Jan 2017, 11:59 AM
Hi,

I am not sure what exactly you want to achieve in this case. Could you please elaborate?

Thank you in advance for your patience and cooperation.  

Regards,
Dimitar
Telerik by Progress
Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
0
میثم
Top achievements
Rank 1
answered on 13 Jan 2017, 12:22 PM
There is not selecteditem and selected index property for splitbutton.
0
Dimitar
Telerik team
answered on 13 Jan 2017, 02:00 PM
Hi,

Yes, it does not, this is not a DropDownList and it does not have selected item. You can only set a DefaultItem which will be executed when clicking the button if there is no DefaultItem, the drop down will be opened.  

If you need a control which allows selecting items use RadDropDownList.  

I hope this will be useful. 

Regards,
Dimitar
Telerik by Progress
Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
0
میثم
Top achievements
Rank 1
answered on 13 Jan 2017, 07:00 PM
Thanks for your guidance. I tried to write a code with this property. And i seached in many sites  . But no success. I would be very grateful if you write a sample code .
0
میثم
Top achievements
Rank 1
answered on 14 Jan 2017, 11:05 AM

Is this true form:

If(radsplitbuttonelement.defaultitem == menuintem1) 

.....

 

0
میثم
Top achievements
Rank 1
answered on 15 Jan 2017, 12:14 PM
I am waiting for your answer.
0
Dimitar
Telerik team
answered on 16 Jan 2017, 08:46 AM
Hi,

You just need to set the default item:
radSplitButtonElement1.DefaultItem = radSplitButtonElement1.Items[3];

I have attached a small sample project that shows how you can use the split button as well.

I hope this will be useful. Let me know if you have additional questions.

Regards,
Dimitar
Telerik by Progress
Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Tags
General Discussions
Asked by
میثم
Top achievements
Rank 1
Answers by
Dimitar
Telerik team
میثم
Top achievements
Rank 1
Share this question
or