PortableSettingsProvider.GetAppSettingsPath C# (CSharp) Method

GetAppSettingsPath() public method

public GetAppSettingsPath ( ) : string
return string
    public virtual string GetAppSettingsPath()
    {
        // used to determine where to store the settings
        var fi = new FileInfo(Application.ExecutablePath);
        return fi.DirectoryName;
    }

Usage Example

Example #1
0
 public MainLogic()
 {
     windows8  = CheckIfWin8OrHigher();
     uiContext = SynchronizationContext.Current;
     //addXImageToList = AddXimageToList;
     Uploader.ProgressBarUpdate                   = ProgressAndIconChange;
     ClipboardMonitor.ClipboardEvent             += new EventHandler(ClipboardChanged);
     BalloonMessage.ClipboardNotificationClicked += new EventHandler(ClipboardUpload);
     CreateSFTPConnectionInfo();
     OverlayRequest          = new InteractionRequest <IConfirmation>();
     this.GifOverlayRequest  = new InteractionRequest <IConfirmation>();
     this.GifEditorRequest   = new InteractionRequest <IConfirmation>();
     this.GifProgressRequest = new InteractionRequest <IConfirmation>();
     this.CancelCommand      = new DelegateCommand(CancelUpload);
     historyXMLPath          = Path.Combine(PortableSettingsProvider.GetAppSettingsPath(), "images.xml");
     Ximages       = ReadXML(historyXMLPath);
     CancelEnabled = false;
     ToggleClipboardMonitor();
     SoundPlayer.Init("custom.wav");
     if (string.IsNullOrWhiteSpace(settings.filePath))
     {
         SetDefaultPath();
     }
     StartUploads();
 }