To reproduce: this.radDateTimePicker1.MaxDate = DateTime.Today; private void radButton1_Click(object sender, EventArgs e) { this.ValidateChildren(); } Workaround: this.radDateTimePicker1.MaxDate = new DateTime( DateTime.Today.Year,DateTime.Today.Month,DateTime.Today.Day, 23,59,59);
If you put RadTextBox on a form, set its Anchor to Bottom \ Left and you show the form using the following code: RadForm1 rf = new RadForm1(); rf.MdiParent = this; rf.WindowState = FormWindowState.Maximized;
Exception is thrown in RadTextBoxControl when the caret blink time is set to none.
To reproduce: Create a Windows Forms project - Add a RadDock. - Add 1 DocumentWindow and 1 ToolWindow to the RadDock control. - Add a RadTextBoxControl to the DocumentWindow. Give it a height that will allow you to easily scroll. - Run the application and enter enough text into the text box to make the scrollbar appear. - Scroll to the bottom of the textbox. - Minimize the application. Workaround: public class MyScroller : TextBoxScroller { public MyScroller(RadScrollBarElement scrollbar) : base(scrollbar) { } public override int Value { get { return base.Value; } set { if (value < this.MaxValue) { base.Value = value; } } } } Change it as follows: radTextBoxControl1.TextBoxElement.ViewElement.VScroller = new MyScroller(radTextBoxControl1.TextBoxElement.VScrollBar);
Workaround: public Form1() { InitializeComponent(); this.radMaskedEditBox1.MaskedEditBoxElement.TextBoxItem.KeyPress += TextBoxItem_KeyPress; } private void TextBoxItem_KeyPress(object sender, KeyPressEventArgs e) { if (e.KeyChar == '-') { this.radMaskedEditBox1.MaskedEditBoxElement.TextBoxItem.SelectionStart = this.radMaskedEditBox1.MaskedEditBoxElement.TextBoxItem.Text.Length; } }
To reproduce: RadSpellChecker radSpellChecker1 = new RadSpellChecker(); public Form1() { InitializeComponent(); RadTextBox radTextBox1 = new RadTextBox(); radTextBox1.Location = new Point(10, 10); this.Controls.Add(radTextBox1); this.radSpellChecker1.AutoSpellCheckControl = radTextBox1; } 1. Enter some valid text. 2. Select the content and right click with the mouse in order to copy the text by using the default context menu. However, the menu does not show. Note: if the control is not spellchecked, it shows default context menu associated with MS TextBox. Workaround: display your own menu with copy/paste options when no misspelled words are available. RadContextMenu menu = new RadContextMenu(); public TestSpellchecker() { InitializeComponent(); RadMenuItem copyItem = new RadMenuItem("Copy"); copyItem.Click += copyItem_Click; menu.Items.Add(copyItem); RadMenuItem pasteItem = new RadMenuItem("Paste"); pasteItem.Click += pasteItem_Click; menu.Items.Add(pasteItem); this.radTextBox1.TextBoxElement.TextBoxItem.TextBoxControl.MouseDown += TextBoxControl_MouseDown; } private void pasteItem_Click(object sender, EventArgs e) { this.radTextBox1.Paste(); } private void copyItem_Click(object sender, EventArgs e) { this.radTextBox1.Copy(); } static Regex wordParser = new Regex(@"[\p{L}\p{N}\p{M}]+(?:[-.'ยด_@][\p{L}|\p{N}|\p{M}]+)*", RegexOptions.Compiled); private void TextBoxControl_MouseDown(object sender, MouseEventArgs e) { if (e.Button == System.Windows.Forms.MouseButtons.Right) { TextBoxSpellChecker tbSpellChecker = this.radSpellChecker1.GetControlSpellChecker(typeof(RadTextBoxControl)) as TextBoxSpellChecker; MatchCollection words = wordParser.Matches(this.radTextBox1.Text); bool containsError = false; foreach (Match word in words) { string text = word.Captures[0].Value; if (!tbSpellChecker.SpellChecker.CheckWordIsCorrect(text, System.Threading.Thread.CurrentThread.CurrentCulture)) { containsError = true; break; } } if (!containsError) { menu.Show(this.radTextBox1, new Point(0,0)); } } }
The following stack trace is only available: <ErrorReport GeneratedDate="2015-10-07 14-10-25 435"><Exception><Type>ArgumentNullException</Type><Message>Value cannot be null. Parameter name: key</Message><Source>mscorlib</Source><TargetSite>Int32 FindEntry(TKey)</TargetSite><StackTrace> at System.Collections.Generic.Dictionary`2.FindEntry(TKey key) at Telerik.WinControls.RichTextBox.Proofing.WordDictionary.GetWordsByMetaphoneKey(String word) at Telerik.WinControls.RichTextBox.Proofing.DocumentSpellChecker.GetSuggestionsForDictionary(IWordDictionary dictionary, Dictionary`2 suggestions, String word) at Telerik.WinControls.RichTextBox.Proofing.DocumentSpellChecker.GetSuggestions(String word, CultureInfo culture) at Telerik.WinControls.UI.SpellCheckWordByWordForm.Initialize(String word, IControlSpellChecker spellCheckingManager) at Telerik.WinControls.UI.SpellCheckWordByWordForm.Telerik.WinControls.RichTextBox.UI.Extensibility.SpellChecking.ISpellCheckForm.Check(RadRichTextBox richTextBox, String word) at Manad.Plus.WindowsUI.Common.Controls.LocalInputBehaviour.ProcessRightMouseButtonDown(MouseEventArgs e) at Telerik.WinControls.RichTextBox.UI.InputBehavior.ProcessMouseDown(MouseEventArgs e) at Telerik.WinControls.RichTextBox.RadRichTextBox.OnMouseDown(MouseEventArgs e) at System.Windows.Forms.Control.WmMouseDown(Message& m, MouseButtons button, Int32 clicks) at System.Windows.Forms.Control.WndProc(Message& m) at Telerik.WinControls.RadControl.WndProc(Message& m) at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)</StackTrace><Data>System.Collections.ListDictionaryInternal</Data><IsTerminating>False</IsTerminating><ExceptionInnerLevel>0</ExceptionInnerLevel>
To reproduce: Me.RadMaskedEditBox1.Mask = "c" Me.RadMaskedEditBox1.MaskType = MaskType.Numeric Me.RadMaskedEditBox1.Value = Nothing Try to enter "123". You will notice that after entering "1", the cursor is positioned after "$" instead of "1". Thus, the entered value will be "$231.00", instead the expected "$123.00" Workaround: initialize the RadMaskedEditBox with Value= 0.
To reproduce: - Set the mask like this: radMaskedEditBox1.Mask = "N0"; radMaskedEditBox1.MaskType = MaskType.Numeric; Set the value to "12345" move the caret to the first position and press '.' Workaround: void radMaskedEditBox1_KeyPress(object sender, KeyPressEventArgs e) { if (e.KeyChar == '.') { e.Handled = true; } }
Please refer to the attached sample project. Workaround: keep the text box invisible until the form is shown.
To reproduce: this.radDateTimePicker1.DateTimePickerElement.TextBoxElement.MaskType = MaskType.FreeFormDateTime; string format = "MM/dd/yyyy - ddd"; radDateTimePicker1.Format = DateTimePickerFormat.Custom; radDateTimePicker1.CustomFormat = format; - Start the application and click the last part Workaround: class MyFreeFormDateTimeProvider : FreeFormDateTimeProvider { public MyFreeFormDateTimeProvider(string mask, CultureInfo culture, RadMaskedEditBoxElement owner) : base(mask, culture, owner) { } public override void SelectNextEditableItem() { if (this.SelectedItemIndex +1 == this.List.Count) { return; } base.SelectNextEditableItem(); } }
To reproduce: - Set the AutoSelectNextPart property to true. - Selelct the entire text and try to enter the date. Workaround: radTimePicker1.TimePickerElement.KeyDown += TimePickerElement_KeyDown; void TimePickerElement_KeyDown(object sender, KeyEventArgs e) { if (this.radTimePicker1.TimePickerElement.MaskedEditBox.TextBoxItem.Text.Trim('A', 'P', 'M', ' ') == this.radTimePicker1.TimePickerElement.MaskedEditBox.TextBoxItem.SelectedText.Trim('A', 'P', 'M', ' ')) { ((MaskDateTimeProvider)radTimePicker1.TimePickerElement.MaskedEditBox.Provider).SelectFirstEditableItem(); e.Handled = true; } }
To reproduce: private void MdiChildForm_Load(object sender, EventArgs e) { radMaskedEditBox1.MaskType = MaskType.Numeric; radMaskedEditBox1.Mask = "n4"; radMaskedEditBox1.NullText = "this is null text" } private void radButton1_Click(object sender, EventArgs e) { radMaskedEditBox1.Value = null; } the issue appears also when the RadmaskedEditBox is configured like this: this.radMaskedEditBox1.MaskType = Telerik.WinControls.UI.MaskType.Standard; this.radMaskedEditBox1.Mask = "0000000"; this.radMaskedEditBox1.NullText = "My null text"; this.radMaskedEditBox1.PromptChar = '_'; WORKAROUND: radMaskedEditBox1.Value = null; radMaskedEditBox1.MaskedEditBoxElement.TextBoxItem.HostedControl.Text = "";
When you inherit from RadTextBox and override the OnKeyPress or OnKeyDown, those events are not fired.
To reproduce: 1. Add UserControl 2. Drag and drop RadPopupEditor and RadPopupContainer 3. Open the smart tag of RadPopupEditor and try to set the AssociatedControl property. You will see error message from attached image. Workaround: Set the AssociatedControl at run time. Here is the code snippet: For C#: public UserControl1() { InitializeComponent(); this.radPopupEditor1.AssociatedControl = this.radPopupContainer1; } For VB: Public Class UserControl1 Inherits UserControl Public Sub New() InitializeComponent() Me.RadPopupEditor1.AssociatedControl = Me.RadPopupContainer1 End Sub End Class
Workaround: RadPopupContainer1.BindingContext = New BindingContext()
Keyboard input does not work in RadDateTimePicker when the Culture is ar-SA
ADD. Popup control which can host controls and be associated with a button or opened on request.
To reproduce: 1. Add a RadTextBox 2. Set the AutoCompleteMode property to SuggestAppend 3. Add a RadSpellChecker and set the AutoSpellCheckControl property the text box 4. Start typing. You will notice that the autocomplete functionality behaves as expected. But the incorrect words are not underlined. Workaround: use RadTextBoxControl