public MainForm() { InitializeComponent(); MainForm.Serial_Comm_True_Ethernet_False = true; LanguageText_Data_Static.CurrentLanguage_Static = "FR"; LanguageForm languageForm = new LanguageForm("Language"); //Lancment du winfowsform pour la langue if (languageForm.ShowDialog() == DialogResult.OK) { Language_Change(LanguageText_Data_Static.CurrentLanguage_Static); } else { System.Environment.Exit(0); } Serial_Settings_Form serial_Settings = new Serial_Settings_Form(); //Lancment du winfowsform pour le serial if (serial_Settings.ShowDialog() == DialogResult.OK) { } }
private void RS232_Settings_Button_Click(object sender, EventArgs e) { //Serial_Input_TextBox.Text += "Port" + "\r\n"; if (MainForm.Serial_Comm_True_Ethernet_False == true) { Serial_Settings_Form serial_Settings = new Serial_Settings_Form(); if (serial_Settings.ShowDialog() == DialogResult.OK) { //Language_Change(languageForm.Loading_MainForm_Language); } } else { Ethernet_Settings_Form ethernet_Settings_Form = new Ethernet_Settings_Form(); if (ethernet_Settings_Form.ShowDialog() == DialogResult.OK) { //Language_Change(languageForm.Loading_MainForm_Language); } } }