>public class TipTraxSettings : mmAppConfiguration >{ > public TipTraxSettings() : base(false) > { > // Specify the settings to be encrypted, and the encryption key > this.SetEncryption("WSUserId,WSPassword", "PacificaSys"); > > // Use a custom Config file > this.ReadKeysFromConfig("TipTrax.Config"); > } > > #region Public Settings Properties > > /// <summary> > /// MyTruckCode Property > /// </summary> > public string MyTruckCode > { > get { return _myTruckCode; } > set { _myTruckCode = value; } > } > private string _myTruckCode = "120"; > > /// <summary> > /// EnableGps Property > /// </summary> > public bool EnableGps > { > get { return _enableGps; } > set { _enableGps = value; } > } > private bool _enableGps = true; >} > >Then in App.cs Add a static public property to get to access them. > >/// <summary> >/// ApplicationSettings Property >/// </summary> >public static TipTraxSettings ApplicationSettings >{ > get > { > > if (_applicationSettings == null) > _applicationSettings = new TipTraxSettings(); > > return _applicationSettings; > } >} >private static TipTraxSettings _applicationSettings; > >Now anywhere in the application I can reference it like this: >if (AppDesktop.ApplicationSettings.EnableGps) >{ > // Do something >} >or >string truckCode = AppDesktop.ApplicationSettings.MyTruckCode; >>