Imports Infragistics.Shared Imports Infragistics.Win Imports Infragistics.Win.Misc Imports Infragistics.Win.FormattedLinkLabel Private Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles button1.Click ' Set the value to text containing a misspelled word for testing purposes. Me.ultraFormattedTextEditor1.Value = "mispeled word" ' Create an UltraSpellChecker instance. You can also put an UltraSpellChecker ' component on the form at design-time. Dim spellChecker As Infragistics.Win.UltraWinSpellChecker.UltraSpellChecker = _ New Infragistics.Win.UltraWinSpellChecker.UltraSpellChecker() ' Set SpellChecker to an instance of UltraSpellChecker. Me.ultraFormattedTextEditor1.SpellChecker = spellChecker ' Specll checking related settings are available on the spell-checker itself. spellChecker.Mode = Infragistics.Win.UltraWinSpellChecker.SpellCheckingMode.AsYouType ' To display a list of suggested words in the context menu when the user ' right-clicks on a misspelled word, set the ContextMenuItems to a value ' that contains SpellingSuggestions flag. Here we are setting it to All ' which enables SpellingSuggestions as well. Me.ultraFormattedTextEditor1.ContextMenuItems = FormattedTextMenuItems.All End Sub
using Infragistics.Shared; using Infragistics.Win; using Infragistics.Win.Misc; using Infragistics.Win.FormattedLinkLabel; using System.Diagnostics; private void button1_Click(object sender, System.EventArgs e) { // Set the value to text containing a misspelled word for testing purposes. this.ultraFormattedTextEditor1.Value = "mispeled word"; // Create an UltraSpellChecker instance. You can also put an UltraSpellChecker // component on the form at design-time. Infragistics.Win.UltraWinSpellChecker.UltraSpellChecker spellChecker = new Infragistics.Win.UltraWinSpellChecker.UltraSpellChecker( ); // Set SpellChecker to an instance of UltraSpellChecker. this.ultraFormattedTextEditor1.SpellChecker = spellChecker; // Specll checking related settings are available on the spell-checker itself. spellChecker.Mode = Infragistics.Win.UltraWinSpellChecker.SpellCheckingMode.AsYouType; // To display a list of suggested words in the context menu when the user // right-clicks on a misspelled word, set the ContextMenuItems to a value // that contains SpellingSuggestions flag. Here we are setting it to All // which enables SpellingSuggestions as well. this.ultraFormattedTextEditor1.ContextMenuItems = FormattedTextMenuItems.All; }