User Dictionary
Priya leads the knowledge-base product at an internal-tools company. Their flagship is a desktop article editor that engineers across the company use to document services, runbooks, and incident postmortems. Engineering writes about products with names like Kestrel, Snowfall, and Aegis-7; about internal tools called tugboat and maelstrom; about people on the on-call rota with surnames the US English dictionary has never heard of. Every postmortem the team writes lights up red.
The annoyance compounds. An engineer typing a 2 a.m. incident report does not want to right-click the same five proper nouns over and over to dismiss them. What Priya needs is for the editor to remember. When an engineer right-clicks Kestrel and picks Add to Dictionary, that word should stop being flagged on their machine -- forever, and across sessions.

The feature is already in the control
The right-click Add to Dictionary menu item ships with the editor. The only thing Priya has to do is tell the control where the per-user dictionary file should live. Two properties on SpellCheckOptions.DictionaryFile drive the behaviour:
UserDictionaryFilePath-- an absolute path to a plain text file. The control creates it the first time a word is added.EnableUserDictionary-- the master switch. Whenfalse, the Add to Dictionary entry is hidden and the file is neither read nor written.
Picking the right folder
Priya's first instinct is to drop the file next to the application .exe. That works on her dev machine and breaks the moment IT pushes the app into Program Files, where standard users cannot write. The right home for a per-user, writable file is Environment.SpecialFolder.LocalApplicationData -- it is per-user, never requires elevation, survives application upgrades, and is the folder Windows guidance has pointed at for two decades.
She wires it up once, in the main form's constructor:
using System;
using System.IO;
public partial class ArticleEditorForm : Form
{
public ArticleEditorForm()
{
InitializeComponent();
// %LOCALAPPDATA%\Contoso\KnowledgeBase\user-dictionary.txt
var localAppData = Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData);
var appFolder = Path.Combine(localAppData, "Contoso", "KnowledgeBase");
Directory.CreateDirectory(appFolder);
var userDictPath = Path.Combine(appFolder, "user-dictionary.txt");
editor.SpellCheckOptions.DictionaryFile.UserDictionaryFilePath = userDictPath;
editor.SpellCheckOptions.DictionaryFile.EnableUserDictionary = true;
}
}Twenty lines later, the next time an engineer right-clicks Kestrel and picks Add to Dictionary, the word is appended to user-dictionary.txt on disk and the squiggle disappears immediately. Restart the application a week later; Kestrel stays clean.

Seeding the dictionary on first run
A month into the rollout, Priya runs a quick poll: every engineer ends up adding the same fifty product names. Asking three hundred people to do that one click at a time is busywork. She ships a seed file with the installer and writes it to the user-dictionary path on first launch if no file is there yet. The format is a plain text file, one word per line, and the spell checker reads it on load and appends to it on every Add to Dictionary:
// Run once at first launch
if (!File.Exists(userDictPath))
{
File.Copy(seedPath: "seed/company-glossary.txt", destFileName: userDictPath);
}
editor.SpellCheckOptions.DictionaryFile.UserDictionaryFilePath = userDictPath;
editor.SpellCheckOptions.DictionaryFile.EnableUserDictionary = true;New engineers join the team with the company glossary already loaded. They never see a red squiggle under Kestrel.
The scenario where you turn it off
Six months after the rollout, Priya's product is adopted by the regulatory-affairs team for drafting filings. Filings go in front of auditors, and the auditors are explicit: end users are not allowed to grow their own vocabulary -- the dictionary must be exactly what the company glossary defines and nothing more. For that build of the application, Priya simply flips the switch off:
editor.SpellCheckOptions.DictionaryFile.EnableUserDictionary = false;The Add to Dictionary menu item disappears, the file on disk is ignored, and the control falls back to the glossary alone. Same code, two builds, two policies.
If you have replaced the engine
Some applications -- see the Custom Spell-Check Engine page -- plug in their own ISpellCheckerEngine implementation. The user-dictionary path still flows through: the control passes it to Initialize(dictionaryPath, affixPath, userDictionaryPath) and routes every Add to Dictionary click into the engine's AddToUserDictionary method. A custom engine is free to persist that word to a plain file, a corporate vocabulary server, or a per-user database -- the control does not care.
What ships
Three properties, one common-sense folder choice, and an optional seed file are everything Priya needed for engineers to stop fighting their editor at 2 a.m. The same wiring -- with one switch flipped -- also satisfies the regulatory team's much stricter policy. Both audiences run the same build.