Esempio n. 1
0
 private void Plugin_exportPath_TextChanged(object sender, TextChangedEventArgs e)
 {
     Params.exportPath = this.Plugin_exportPath.Text;
     if (this.Plugin_exportPath.Text != "")
     {
         ExportDataCmd.setEnable(true);
     }
     else
     {
         ExportDataCmd.setEnable(false);
     }
 }
Esempio n. 2
0
 private void Plugin_exportName_TextChanged(object sender, TextChangedEventArgs e)
 {
     if (this.Plugin_exportName.Text != "")
     {
         Params.Instance.exportName = this.Plugin_exportName.Text;
         if (Params.exportPath != null && Params.exportPath != "")
         {
             ExportDataCmd.setEnable(true);
         }
     }
     else
     {
         Params.Instance.exportName = Params.DEFAULT_EXPORTNAME;
     }
 }
Esempio n. 3
0
        private void ExportBrowseButton_Click(object sender, RoutedEventArgs e)
        {
            // Configure open file dialog box
            Microsoft.Win32.OpenFileDialog dlg = new Microsoft.Win32.OpenFileDialog();
            Nullable <bool> result             = dlg.ShowDialog();

            if (result == true)
            {
                this.Plugin_exportPath.Text = dlg.FileName;
                Params.exportPath           = this.Plugin_exportPath.Text;
            }

            if (this.Plugin_exportPath.Text != "")
            {
                ExportDataCmd.setEnable(true);
            }
            else
            {
                ExportDataCmd.setEnable(false);
            }
        }
Esempio n. 4
0
        public void LoadUserSettings(string settingsString)
        {
            string[] stringSeparators = new string[] { Params.DELIM };
            string[] result           = settingsString.Split(stringSeparators, StringSplitOptions.None);

            if (result != null)
            {
                Params.Instance.exportName  = result[0];
                this.Plugin_exportName.Text = Params.Instance.exportName;

                if (result.Length > 1)
                {
                    if (result[1] != "")
                    {
                        Params.exportPath           = result[1];
                        this.Plugin_exportPath.Text = Params.exportPath;
                        ExportDataCmd.setEnable(true);
                    }
                }

                if (result.Length > 2)
                {
                    Params.Instance.importName  = result[2];
                    this.Plugin_importName.Text = Params.Instance.importName;
                }

                if (result.Length > 3)
                {
                    if (result[3] != "")
                    {
                        Params.importPath           = result[3];
                        this.Plugin_importPath.Text = Params.importPath;
                        ImportDataCmd.setEnable(true);
                    }
                }
            }
        }