Run the project and open the overflow menu. If you focus one of the editors and press the down arrow, the following error occurs:
at Telerik.WinControls.RadMessageFilter.NotifyGetMessageEvent(Message& msg)1. Add a CommandBarDropDownButton with one RadMenuItem and one RadMenuButtonItem
2. Set the same SvgImage for both items and set the DisplayStyle to Image.
3. If you run the project, you will notice that the RadMenuItem shows the SVG, but the RadMenuButtonItem doesn't show it.
Workaround: set the RadMenuButtonItem.ButtonElement.SvgImage
Hi,
I have a CommandBar that contains multiple CommandBarDropDownLists. When they get shown, the tooltip is supposed to be the selected item's text. What actually happens though is that the tooltip is basically always the text of the first item in the list. I've tried several things, to no avail. Some of the things I've tried include overriding the VisualItemFormatting event of the CommandBarDropDownLists, working with the TextChanged event to change the tooltip, and trying to change the tooltip in the SelectedIndexChanged event that is also being overriden for other purposes as well. None of these has changed the behaviour described above.
Thank you in advance for your time! I know this is probably simple and I am just missing something, but I just can't figure it out.
Best regards,
Matei
Hi
Found a funny behavior in the RadCommandbar.
Just try this:
In attachment I created a small movie clip that illustrates this behavior.
Kind regards,
Peter.
I set the ShowClearButton on the design-time but the clear button not displayed when I run the application.
However, it works fun when I set the ShowClearButton programatically.
commandBarTextBox1.TextBoxElement.ShowClearButton = true;
Do you know why?
Please refer to the attached gif file and the provided sample project.
//Workaround 1 this.commandBarDropDownList1.CommandBarDropDownListElement.EditableElement.TextBox.TextBoxItem.UseDefaultDisabledPaint = false;
this.commandBarDropDownList1.CommandBarDropDownListElement.EditableElement.TextBox.TextBoxItem.Enabled = false;
//Workaround 2
private void CommandBarDropDownList1_SelectedIndexChanged(object sender, Telerik.WinControls.UI.Data.PositionChangedEventArgs e)
{
this.commandBarDropDownList1.CommandBarDropDownListElement.EditableElement.TextBox.TextBoxItem.SelectionLength = 0;
this.commandBarDropDownList1.CommandBarDropDownListElement.EditableElement.TextBox.TextBoxItem.SelectionStart = 0;
}
private void TextBoxItem_PropertyChanged(object sender, PropertyChangedEventArgs e)
{
this.commandBarDropDownList1.CommandBarDropDownListElement.EditableElement.TextBox.TextBoxItem.SelectionLength = 0;
this.commandBarDropDownList1.CommandBarDropDownListElement.EditableElement.TextBox.TextBoxItem.SelectionStart = 0;
}
Workaround: Set it in code: commandBarMaskedEditBox1.CommandBarMaskedTextBoxElement.MaskType = Telerik.WinControls.UI.MaskType.Numeric; commandBarMaskedEditBox1.CommandBarMaskedTextBoxElement.Mask = "d";
To reproduce: 1. Create a project 2. Add a Telerik form 3. Add a RadCommandBar 4. Add some buttons 5. Debug application (forget you are running application) 6. Click on add button on command bar. As a result, Visual studio Crashes. Note: if you perform the same steps with RadRibbonBar a message is shown that the file can't be modified while debugging. Please refer to the attached screenshot.
Use attached to reproduce.
To reproduce: - Run the attached project, maximize the form and click the drop-down buttons. Workaround: commandBarDropDownButton3.DropDownMenu.PopupOpening += DropDownMenu_PopupOpening; private void DropDownMenu_PopupOpening(object sender, CancelEventArgs args) { var e = args as RadPopupOpeningEventArgs; var ownerElement = (sender as RadDropDownMenu).OwnerElement; var loc = ownerElement.ElementTree.Control.PointToScreen(ownerElement.ControlBoundingRectangle.Location); loc.Y += ownerElement.ControlBoundingRectangle.Height; loc.X -= ((sender as RadDropDownMenu).Width - ownerElement.ControlBoundingRectangle.Width); e.CustomLocation = loc; }
To reproduce: - Add some controls to a command bar. - Get the PreferredSize like this: Console.WriteLine(radCommandBar1.PreferredSize.ToString()); Workaround: class MyCommandBar : RadCommandBar { public override Size GetPreferredSize(Size proposedSize) { if (proposedSize.Width == 0 && proposedSize.Height == 0) { return this.Size; } return base.GetPreferredSize(proposedSize); } }
Workaround: set the RadCommandBar.EnableRadAccessibilityObjects property to false.
Workaround: use the attached below theme files. How custom themes can be loaded - http://www.telerik.com/help/winforms/themes-using-custom-themes.html
Workaround: public partial class RadForm1 : Telerik.WinControls.UI.RadForm { public RadForm1() { InitializeComponent(); this.commandBarDropDownButton2.DropDownMenu.DropDownOpening += DropDownMenu_DropDownOpening; } private void DropDownMenu_DropDownOpening(object sender, CancelEventArgs e) { if (this.WindowState == FormWindowState.Maximized) { RadDropDownMenu dMenu = sender as RadDropDownMenu; RadPopupOpeningEventArgs eventArgs = (RadPopupOpeningEventArgs)e; eventArgs.CustomLocation = new System.Drawing.Point(eventArgs.CustomLocation.X + this.commandBarDropDownButton2.Size.Width, eventArgs.CustomLocation.Y); } } }
To reproduce: add a RadCommandBar to the form with several CommandBarStripElements. Change the Name property for one of the CommandBarStripElements at design time. You will notice that the new name is not serialized in the designer file.
To reproduce: Add a RadCommandBar with a row and a strip. Add a CommandBarSplitButton and subscribe to its Click event. You will see that when you click the arrow button the event will be fired. In result you cannot distinguish whether the arrow button is clicked. Workaround: private bool arrowButtonClicked; void ArrowPart_Click(object sender, EventArgs e) { this.arrowButtonClicked = true; //... CommandBarSplitButton.ArrowPart logic } void button_Click(object sender, EventArgs e) { if (this.arrowButtonClicked) { this.arrowButtonClicked = false; return; } //...CommandBarSplitButton logic }