Пример #1
0
    protected void PrepareFormCheckBoxes()
    {
        ASPxSpellChecker spellChecker = ((ASPxSpellChecker)NamingContainer);

        chkbEmails.Checked    = spellChecker.SettingsSpelling.IgnoreEmails;
        chkbMixedCase.Checked = spellChecker.SettingsSpelling.IgnoreMixedCaseWords;
        chkbNumbers.Checked   = spellChecker.SettingsSpelling.IgnoreWordsWithNumber;
        chkbUpperCase.Checked = spellChecker.SettingsSpelling.IgnoreUpperCaseWords;
        chkbUrls.Checked      = spellChecker.SettingsSpelling.IgnoreUrls;
        chkbTags.Checked      = spellChecker.SettingsSpelling.IgnoreMarkupTags;
    }
Пример #2
0
        protected void ASPxSpellChecker1_WordAdded(object sender, WordAddedEventArgs e)
        {
            ASPxSpellChecker             checker = sender as ASPxSpellChecker;
            SpellCheckerCustomDictionary dic     = checker.GetCustomDictionary();

            if (dic != null)
            {
                StringBuilder stb = new StringBuilder();
                for (int i = 0; i < dic.WordCount; i++)
                {
                    stb.AppendLine(dic[i]);
                }
                using (StreamWriter writer = new StreamWriter(userDictPath)) {
                    writer.Write(stb.ToString());
                }
            }
        }