コード例 #1
0
ファイル: Backup.xaml.cs プロジェクト: TrireksaDevelopOrg/3MG
        private void Button_Click(object sender, RoutedEventArgs e)
        {
            var f = new FolderBrowserDialog();

            f.SelectedPath = SettingConfiguration.GetStringValue("BackupPath");
            f.ShowDialog();
            if (f != null && !string.IsNullOrEmpty(f.SelectedPath))
            {
                SettingConfiguration.UpdateKey("BackupPath", f.SelectedPath);
                vm.DataPath = f.SelectedPath + vm.GetFileName();
            }
        }
コード例 #2
0
ファイル: Backup.xaml.cs プロジェクト: TrireksaDevelopOrg/3MG
        public BackUpViewModel()
        {
            MyTitle          = "Backup Data";
            this.OnError    += BackUpViewModel_OnError;
            this.OnComplete += BackUpViewModel_OnComplete;
            TotalData        = 100;
            ProgressValue    = 0;
            var path = SettingConfiguration.GetStringValue("BackupPath");

            if (!string.IsNullOrEmpty(path))
            {
                DataPath = path + GetFileName();
            }
        }