15. Settings

SOME WINDOWS FORMS APPLICATIONS can happily operate in a microcosm, but most real-world applications rely on information from the environment around them. This information can come from many sources and is dictated by an application, its users, and even the machine on which an application executes.

.NET provides several specialized classes that applications can use to inspect their operational environment, as well as a comprehensive system for managing application- and user-specific settings. There are several additional options along these lines, including environment variables, command line arguments, .config files, the Registry, and special folders.

The Application Environment

During its lifetime, an application runs in a certain ...

Get Windows Forms 2.0 Programming now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.