Log In
Home
Support
Demos
Documentation
Blogs
Training
Webinars
[Expand]General Information
[Expand]WinForms Controls
[Collapse]ASP.NET Controls and MVC Extensions
 [Expand]Prerequisites
 [Expand]What's Installed
 [Expand]Common Concepts
 [Collapse]ASP.NET WebForms Controls
  [Expand]Reporting
  [Expand]Chart Control
  [Expand]Grid View
  [Expand]Card View
  [Expand]Vertical Grid
  [Expand]Spreadsheet
  [Expand]Rich Text Editor
  [Expand]Image and Data Browsing
  [Expand]Docking and Popups
  [Expand]Site Navigation and Layout
  [Expand]File Management
  [Expand]Multi-Use Site Controls
  [Expand]Scheduler
  [Expand]HTML Editor
  [Expand]Pivot Grid
  [Expand]Tree List
  [Expand]Gauges
  [Expand]Data Editors
  [Collapse]Spell Checker
   [Expand]Product Information
    Getting Started
   [Expand]Fundamentals
   [Expand]Visual Elements
   [Expand]Design-Time Features
   [Collapse]Examples
     How to: Load a User-Specific Dictionary and Update It During Spell Check
  [Expand]Query Builder
 [Expand]ASP.NET MVC Extensions
 [Expand]Localization
 [Expand]Redistribution and Deployment
  Get More Help
 [Expand]API Reference
[Expand]ASP.NET Bootstrap Controls
[Expand]WPF Controls
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Document Server
[Expand]Reporting
[Expand]Report Server
[Expand]Dashboard
[Expand]eXpressApp Framework
[Expand]CodeRush
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation

How to: Load a User-Specific Dictionary and Update It During Spell Check

A custom dictionary for ASPxSpellChecker can be specified in the page markup or created in the code-behind file. This dictionary is the same for different users. Words added to a custom dictionary during a spell check are stored in a session cache, so the original custom dictionary remains intact.

This article demonstrates how to load a dictionary that is specific to a particular user. The user has the ability to extend this dictionary. To accomplish this task, you should handle two ASPxSpellChecker events - the ASPxSpellChecker.CustomDictionaryLoading event and the ASPxSpellChecker.WordAdded event.

Expanded CustomDictionaryLoading Event

Show Me

A complete sample project is available in the DevExpress Code Examples database at http://www.devexpress.com/example=E3002.

The following code snippet illustrates that you can handle the ASPxSpellChecker.CustomDictionaryLoading event to load a custom dictionary from a stream. Note that the ASPxSpellChecker control already has an ASPxSpellCheckerCustomDictionary object in its collection of dictionaries. When the custom dictionary is loading, it fires an event allowing you to load a user-specific dictionary.

Expanded WordAdded Event

Show Me

A complete sample project is available in the DevExpress Code Examples database at http://www.devexpress.com/example=E3002.

This code illustrates that you can handle the ASPxSpellChecker.WordAdded event to save an updated custom dictionary to the original location. The ASPxSpellChecker.GetCustomDictionary method enables you to access a custom dictionary that is currently in use.

Expanded See Also

How would you rate this topic?​​​​​​​