private void LoadNormalizedData_Click(object sender, EventArgs e) { this.LoadNormalizedDataSet.Filter = "njson|*.njson|ovn|*.ovn|txt|*.txt"; this.LoadNormalizedDataSet.ShowDialog(); if (ErrorContainer.no2(LoadNormalizedDataSet.FileName) == true) { return; } if (LoadNormalizedDataSet.FilterIndex == 1) { this.DataSetShowBox.DataSource = NormalizedDataSetSave.opentFromJSON(LoadNormalizedDataSet.FileName); } else if (LoadNormalizedDataSet.FilterIndex == 2) { this.DataSetShowBox.DataSource = NormalizedDataSetSave.openFromOwnFromat(LoadNormalizedDataSet.FileName); } else if (LoadNormalizedDataSet.FilterIndex == 3) { this.DataSetShowBox.DataSource = NormalizedDataSetSave.openFromTXT(LoadNormalizedDataSet.FileName); } this.ConfigShowBox.Clear(); this.RowsToNormalizeBox.Visible = false; this.LabelRowsToNormalize.Visible = false; this.LoadConfigFile.Enabled = false; this.LoadDataSet.Enabled = false; this.ButtonChangeConfig.Enabled = false; this.StartNormalize.Enabled = false; this.SaveNormalizedData.Enabled = false; this.DeflatuNormalizeRange.Enabled = false; this.StatusBox2.Text = "Status: Tylko do odczytu "; this.DeletedRowText.Clear(); this.StatusBox1.Clear(); this.StatusBox2.BackColor = Color.Blue; this.StatusBox1.BackColor = Color.White; this.DeletedRowText.BackColor = Color.White; }
private void SaveNormalizedData_Click(object sender, EventArgs e) { this.SaveDataFile.Filter = "njson|*.njson|ovn|*.ovn|txt|*.txt"; this.SaveDataFile.ShowDialog(); if (ErrorContainer.no2(SaveDataFile.FileName) == true) { return; } if (SaveDataFile.FilterIndex == 1) { NormalizedDataSetSave.saveToJSON(this.SaveDataFile.FileName, Program.nnDataset.NormalizedDataSetView()); this.StartNormalize.Enabled = false; this.DeflatuNormalizeRange.Enabled = false; this.RangeNormalizeMin.Enabled = false; this.RangeNormalizeMax.Enabled = false; } else if (SaveDataFile.FilterIndex == 2) { NormalizedDataSetSave.saveToOwnFormat(this.SaveDataFile.FileName, Program.nnDataset.dataset); this.StartNormalize.Enabled = false; this.DeflatuNormalizeRange.Enabled = false; this.RangeNormalizeMin.Enabled = false; this.RangeNormalizeMax.Enabled = false; } else if (SaveDataFile.FilterIndex == 3) { NormalizedDataSetSave.saveToTXT(this.SaveDataFile.FileName, Program.nnDataset.NormalizedDataSetView()); this.StartNormalize.Enabled = false; this.DeflatuNormalizeRange.Enabled = false; this.RangeNormalizeMin.Enabled = false; this.RangeNormalizeMax.Enabled = false; } MessageBox.Show("Plik został zapisany", this.SaveDataFile.FileName); }