To reproduce: use the following code: this.radSpinEditor1.ScreenTipNeeded += screenTipNeeded; private void screenTipNeeded(object sender, Telerik.WinControls.ScreenTipNeededEventArgs e) { Console.WriteLine(e.Item); RadOffice2007ScreenTipElement screenTip = e.Item.ScreenTip as RadOffice2007ScreenTipElement; if (screenTip == null) { e.Item.ScreenTip = new RadOffice2007ScreenTipElement(); screenTip = e.Item.ScreenTip as RadOffice2007ScreenTipElement; } screenTip.CaptionLabel.Text = "Title of tooltip"; screenTip.MainTextLabel.Text = "Text of tooltip"; } Workaround: this.radSpinEditor1.SpinElement.TextBoxItem.HostedControl.MouseLeave += radSpinEditor1_MouseLeave; private void radSpinEditor1_MouseLeave(object sender, EventArgs e) { if (this.radSpinEditor1.SpinElement.TextBoxItem.ScreenTip != null) { this.radSpinEditor1.ElementTree.ComponentTreeHandler.Behavior.HideScreenTip(); } }
To reproduce: Add a RadTextBoxControl and start the application. Start the touch keyboard of windows and switch to handwriting mode (by clicking at the bottom right of the keyboard on the little keyboard icon). Type a letter and insert it. You will see that the letter will be inserted twice and the TextChanged event will be raised twice. Workaround: Use RadTextBox instead.
The default directory is not set correctly when the dialog is SaveFileDialog.
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); } }
To reproduce use the following configuration for the DateTimePicker: public Form1() { InitializeComponent(); DateTime start = DateTime.Parse("2012/7/1 00:00:00"); this.RadDateTimePicker1.ShowUpDown = true; this.RadDateTimePicker1.Format = DateTimePickerFormat.Custom; this.RadDateTimePicker1.DateTimePickerElement.ShowCurrentTime = false; this.RadDateTimePicker1.MinDate = start; this.RadDateTimePicker1.DateTimePickerElement.CustomFormat = "HH:mm"; this.RadDateTimePicker1.MaxDate = start + TimeSpan.FromMinutes(1440); this.RadDateTimePicker1.Value = start +TimeSpan.FromMinutes(1); this.RadDateTimePicker1.Enter += new EventHandler(this.ConfigStartDelayTime_Enter); } void ConfigStartDelayTime_Enter(object sender, EventArgs e) { RadMaskedEditBoxElement element = this.RadDateTimePicker1.DateTimePickerElement.TextBoxElement.TextBoxItem.Parent as RadMaskedEditBoxElement; MaskDateTimeProvider provider = element.Provider as MaskDateTimeProvider; provider.SelectLastItem(); }
To reproduce: - Open the RadColorDialogForm (for example to edit color property in RadProeprtyGrid) - Switch to the web tab. -Press the 'a' key several times.
Resolution: TextBlockElement was removed from EditUI elements, since it is a dynamically added.
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); } }
When the control is disabled it size is changed/
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); }
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.
If negative numbers are required to be displayed in brackets , e.g. ($1234,56) instead of -$1234,56, you should apply the desired NumberFormatInfo.CurrencyNegativePattern http://msdn.microsoft.com/en-us/library/system.globalization.numberformatinfo.currencynegativepattern(v=vs.110).aspx However, the NumericCharacterTextBoxProvider clears the brackets. CultureInfo culture = CultureInfo.CreateSpecificCulture("en-US"); NumberFormatInfo info = new NumberFormatInfo(); info.CurrencyNegativePattern = 0; info.CurrencySymbol = "$"; culture.NumberFormat = info; this.radMaskedEditBox2.Culture = culture; this.radMaskedEditBox2.MaskType = Telerik.WinControls.UI.MaskType.Numeric; this.radMaskedEditBox2.Mask = "c2"; this.radMaskedEditBox2.Value = -1234.56;
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.
When one is typing using Chinese characters, each character is inserted twice.
To reproduce use the following code: radDateTimePicker1.Format = DateTimePickerFormat.Custom; radDateTimePicker1.CustomFormat = "MM/dd/yyyy hh:mm tt"; (this.radDateTimePicker1.DateTimePickerElement.TextBoxElement.Provider as MaskDateTimeProvider).AutoSelectNextPart = true; now, in the first part, type in "10" and you will be auto moved to the second part. Then, press back, to go back to the first part, and try to type in "01" (entering January). The result is that when you press "0" you are moved to the second part, hence "01" cannot be entered.
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);