8 Answers, 1 is accepted
0
Hi Miki,
Thank you for writing.
Yes, you can add spin control as menu item in RadSplitButton. Here is an example:
More information regarding this matter is available here: http://www.telerik.com/help/winforms/menus-menu-working-with-radmenu-items-nesting-controls-in-menu-items.html.
I hope that you find this information useful. Should you have any other questions, do not hesitate to contact us.
Regards,
Stefan
Telerik
Thank you for writing.
Yes, you can add spin control as menu item in RadSplitButton. Here is an example:
RadSpinElement spinElement =
new
RadSpinElement();
splitButton.Items.Add(spinElement);
More information regarding this matter is available here: http://www.telerik.com/help/winforms/menus-menu-working-with-radmenu-items-nesting-controls-in-menu-items.html.
I hope that you find this information useful. Should you have any other questions, do not hesitate to contact us.
Regards,
Stefan
Telerik
Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.
0
miki
Top achievements
Rank 1
answered on 02 Jan 2015, 05:47 PM
That's work great !
can i also add simple text before this element ?
can i also add simple text before this element ?
0
miki
Top achievements
Rank 1
answered on 02 Jan 2015, 06:15 PM
I add RadLabelElement before this new RadSpinElement but is it possible to add this RadLabelElement in the same line of one of my radMenuItem ? (not above or after)
0
Hello Miki,
Thank you for writing back.
You can use a StackLayoutElement as a container and add the RadLabelElement and the RadSpinElement to its Children collection:
I hope this information helps. If you have any additional questions, please let me know.
Regards,
Desislava
Telerik
Thank you for writing back.
You can use a StackLayoutElement as a container and add the RadLabelElement and the RadSpinElement to its Children collection:
public
Form1()
{
InitializeComponent();
StackLayoutElement stack =
new
StackLayoutElement();
stack.StretchHorizontally =
true
;
RadLabelElement label =
new
RadLabelElement();
label.Text =
"text"
;
RadSpinElement spinElement =
new
RadSpinElement();
stack.Children.Add(label);
stack.Children.Add(spinElement);
this
.radSplitButton1.Items.Add(stack);
}
I hope this information helps. If you have any additional questions, please let me know.
Regards,
Desislava
Telerik
Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.
0
miki
Top achievements
Rank 1
answered on 08 Jan 2015, 11:54 AM
That's work great thanks, BTW i try t define new size:
but it seems that it has no effect and nothing changed, am i doing something wrong ?
spinElement .Size =
new
System.Drawing.Size(50, 20);
but it seems that it has no effect and nothing changed, am i doing something wrong ?
0
Hi Miki,
You can use the MInSize/MaxSize properties to set the spit element size.
Regards,
Stefan
Telerik
You can use the MInSize/MaxSize properties to set the spit element size.
Regards,
Stefan
Telerik
Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.
0
miki
Top achievements
Rank 1
answered on 12 Jan 2015, 05:02 PM
Thanks that's works fine.
BTW is it possible to insert Image before the text and not between the text and the RadSpinElement ?
BTW is it possible to insert Image before the text and not between the text and the RadSpinElement ?
0
Hello Miki,
Thank you for writing back.
In order to insert an image before the text, you can set the RadLabelElement.Image property to the desired picture and set the RadLabelElement.TextImageRelation property to ImageBeforeText:
I hope this information helps. If you have any additional questions, please let me know.
Regards,
Desislava
Telerik
Thank you for writing back.
In order to insert an image before the text, you can set the RadLabelElement.Image property to the desired picture and set the RadLabelElement.TextImageRelation property to ImageBeforeText:
StackLayoutElement stack =
new
StackLayoutElement();
stack.StretchHorizontally =
true
;
RadLabelElement label =
new
RadLabelElement();
label.Image = Properties.Resources.crop;
label.TextImageRelation = TextImageRelation.ImageBeforeText;
label.Text =
"text"
;
RadSpinElement spinElement =
new
RadSpinElement();
stack.Children.Add(label);
stack.Children.Add(spinElement);
this
.radSplitButton1.Items.Add(stack);
I hope this information helps. If you have any additional questions, please let me know.
Regards,
Desislava
Telerik
Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.