To reproduce: add a RadTextBoxControl and use the following code snippet: private void radTextBoxControl1_KeyPress(object sender, KeyPressEventArgs e) { if (e.KeyChar == 13) { radTextBoxControl1.Clear(); } } When you enter some text and hit Enter, the text is cleared, but the caret position remains the same. Workaround: private void radTextBoxControl1_KeyPress(object sender, KeyPressEventArgs e) { if (e.KeyChar == 13) { radTextBoxControl1.Clear(); radTextBoxControl1.CaretIndex = 0; } }
To reproduce: 1. Add RadAutoCompleteBox with few items 2. Set the AutoCompleteMode property to SuggestAppend and the WordWrap property to true 3. Start the project and enter 2 times space key. After that press enter key and you will see an exception
To reproduce: Add a RadSpellChecker and a RadTextBox. Load a custom dictionary for RadTextBox: DocumentSpellCheckerspellChecker = checker.GetControlSpellChecker(typeof(RadTextBox)).SpellChecker asDocumentSpellChecker; WordDictionarydict = newWordDictionary(); using(MemoryStreamms = newMemoryStream(File.ReadAllBytes("sv-SE.tdf"))) { dict.Load(ms); } spellChecker.AddDictionary(dict, CultureInfo.CurrentCulture); On a button click spell check the textbox when it has the following text: Varfor fungärar innte dettta this.checker.SpellCheckMode = SpellCheckMode.AllAtOnce; this.checker.Check(this.textBox); You will see that the suggested words are not in Swedish. Workaround: Add the dictionary to the RadRichTextBox spell checker: DocumentSpellCheckerrichSpellChecker = checker.GetControlSpellChecker(typeof(RadRichTextBox)).SpellChecker asDocumentSpellChecker; richSpellChecker.AddDictionary(dict, CultureInfo.CurrentCulture);
Add a RadAutoCompleteBox with some data source and dock it to top of the Form. Start the Application and stretch the form to the second screen. Autocomplete some items, you will notice that the dropdown will not be shown on the correct position. Also at some point when you are reaching the end of the first screen it will be displayed on the seconds screen. Workaround: (this.AutoCompleteBox.TextBoxElement as RadAutoCompleteBoxElement).AutoCompleteDropDown.PopupOpening += AutoCompleteDropDown_PopupOpening; .... void AutoCompleteDropDown_PopupOpening(object sender, CancelEventArgs args) { var e = args as RadPopupOpeningEventArgs; var popup = sender as RadTextBoxAutoCompleteDropDown; bool isOnTwoScreens = false; if (this.Location.X < Screen.PrimaryScreen.WorkingArea.Width && this.Location.X + this.Width > Screen.PrimaryScreen.WorkingArea.Width) { isOnTwoScreens = true; } if (popup.Width + e.CustomLocation.X > Screen.PrimaryScreen.WorkingArea.Width && isOnTwoScreens) { e.CustomLocation = new Point(e.CustomLocation.X - Screen.PrimaryScreen.WorkingArea.Width, e.CustomLocation.Y); } }
Please refer to the attached picture. Workaround: private void Form1_Load(object sender, EventArgs e) { this.radDateTimePicker1.DateTimePickerElement.CheckBox.CheckMarkPrimitive.CheckElement.Margin = new Padding(-2, -2, 0, 0); }
When the control is disabled it size is changed/
To reproduce: - Use the following mask: "+56000000000". - Then type 5 when the whole text is selected. - The caret move to 5 instead of inserting it in the text box like in the default .NET control.
To reproduce: public Form1() { InitializeComponent(); this.radAutoCompleteBox1.AutoCompleteDataSource = ReturnDummyDataTable(); this.radAutoCompleteBox1.AutoCompleteDisplayMember = "Sum"; this.radAutoCompleteBox1.AutoCompleteValueMember = "Answer"; } private DataTable ReturnDummyDataTable() { DataTable dt = new DataTable(); dt.Columns.Add("Sum"); dt.Columns.Add("Answer"); for (int i = 0; i <= 50; i++) { DataRow DR = default(DataRow); DR = dt.NewRow(); DR[0] = i + " + 1"; DR[1] = (i + 1); i += 1; dt.Rows.Add(DR); } return dt; } private void radButton1_Click(object sender, EventArgs e) { string Buffer = ""; if (this.radAutoCompleteBox1.Items.Count == 0) { } else { foreach (RadTokenizedTextItem item in this.radAutoCompleteBox1.Items) { if (Buffer.Length > 1) { Buffer = Buffer + Environment.NewLine + item.Text + " " + "= " + item.Value; } else { Buffer = item.Text + " " + "= " + item.Value; } } MessageBox.Show(Buffer, "Selected Items", MessageBoxButtons.OK, MessageBoxIcon.Information); } } Workaround: set the AutoCompleteDataSource property after setting the AutoCompleteDisplayMember and the AutoCompleteValueMember properties.
To reproduce: - Open the RadColorDialogForm (for example to edit color property in RadProeprtyGrid) - Switch to the web tab. -Press the 'a' key several times.
The TimePickerElement of RadTimePicker does not expose any events. However, events are needed if one needs to use this picker as an element, let's say in RadRibbonBar.
Allow RadSpellChecker to perform check spelling for many controls. Reason for denial: The RadSpellCheker knows the associated document and for example if a user presses ignore all (in as you type) this should be ignored only for specific documents. Also spell checker is inherited from MS component named 'Native Windows' which allows spell checker to receive a WND messages from the associated control.
Description: RadMaskedEditBox (with MaskType=Numeric and Mask = "c") is bound to a property of type decimal. If you type in 15 it goes into the maskedEditbox as 51. Reproduce: -add a BindingSource (DataSource is set to some data table: for example "Products") -add a BindingNavigator (Binding Source is set to the previously added bindingNavigator1) -add a RadMaskedEditBox (with MaskType=Numeric and Mask = "c") with DataBindings: Value => bindingSource1 - UnitPrice -add a new record using the yellow plus sign button in the navigator; get to the price field and just start typing your number: if you type in 15, it goes into the RadMaskedEditBox as 51. Workaround: Bind to Text instead of binding to Value of the RadMaskedEditBox this.radMaskedEditBox1.DataBindings.Add(new Binding("Text", bindingSource1, "UnitPrice", true)); Resolution: RadMaskedEditBox with currency mask does not support null values. Default value must be 0 instead null. Please use the following code snippet: this.mePrice.DataBindings.Add(new System.Windows.Forms.Binding("Value", this.bindingSource1, "Price", true, System.Windows.Forms.DataSourceUpdateMode.OnPropertyChanged, 0, "C2"));
When using CustomDictionary: DocumentSpellChecker checker = this.radRichTextBoxResponses.SpellChecker as DocumentSpellChecker; RadIsolatedStorageCustomDictionary dict = checker.GetCustomDictionary(new CultureInfo("en-US")) as RadIsolatedStorageCustomDictionary; Adding words to the dictionary using the SpellCheck form saves them to the CustomDictionary.txt file created by the isolated storage. However, the words loaded in memory are not being updated. Currently they can be updated by invoking the following method with reflection: dict.GetType().GetMethod("ReadIsolatedStorage", BindingFlags.Instance | BindingFlags.NonPublic).Invoke(dict, null); This method should be made public.
To reproduce: - Add default .net RichTextBox to a blank form. - Add a contexmenu strip (again .net one) to the RichTextBox. - Spell check using RadSpellChecker and you will notice that the menu cannot be opened after that. Workaround: void richTextBox1_MouseDown(object sender, MouseEventArgs e) { if (e.Button == System.Windows.Forms.MouseButtons.Right) { richTextBox1.ContextMenuStrip.Show(this.richTextBox1, e.Location); } }
Steps to reproduce: Set MaskType to Numeric and Mask = "n2". Click into the field to deselect contents. Caret is at the end of the string. Backspace twice and the data entry caret now jumps to BEFORE the decimal point. Workaround: this.RadMaskedEditBox.KeyPress += new KeyPressEventHandler(RadMaskedEditBox_KeyPress); } void RadMaskedEditBox_KeyPress(object sender, KeyPressEventArgs e) { RadMaskedEditBox textBox = ((RadMaskedEditBox)sender); int selectionStart = textBox.SelectionStart; bool beforePoint = selectionStart - 2 >= 0 && textBox.Text[selectionStart - 2] == '.'; if (e.KeyChar == 8 && beforePoint) { NumericMaskTextBoxProvider numericProvider = (NumericMaskTextBoxProvider)textBox.MaskedEditBoxElement.Provider; numericProvider.KeyPress(sender, e); e.Handled = true; textBox.SelectionStart++; } }
When MaskedEditBox uses currency mask (c) and the culture is he-IL, user input is entered incorrectly.
To reproduce: - Subscribe to MaskedEditBox Element PropertyChanged event. - You will notice that when you changing the value will not raise the event. Workaround: You can track the Text property for changes and parse the text to appropriate value.
Despite the fact that the elements of RadTextBox have ToolTipText and AutoToolTip properties, one can't set the tooltip at design-time. We should consider whether we should continue using these properties or introduce a new method to allow for setting tooltips at design-time. Resolution: Open 'Edit UI elements' and set the Tooltip property of RadTextBoxItem
To reproduce: - Add a TextBox and a button to a blank form. - Subscribe to the following Validating event handler: void radTextBox1_Validating(object sender, CancelEventArgs e) { Console.WriteLine("Validating"); e.Cancel = true; }