private void cmbLanguage_SelectedIndexChanged(object sender, EventArgs e) { CompilePanel.Controls.Clear(); ClearResults(); m_CompileOptionsPanel = null; if (cmbLanguage.SelectedItem != null) { ILanguage l = (ILanguage)cmbLanguage.SelectedItem; CompilePanel.Controls.Add(l.OptionsPanel.Panel); m_CompileOptionsPanel = l.OptionsPanel; try { txtCode.SetHighlighting(l.Name); } catch (System.Exception ex) { MessageBox.Show(ex.Message, "Uh-oh", MessageBoxButtons.OK, MessageBoxIcon.Error); } } }
private void cmbLanguage_SelectedIndexChanged(object sender, EventArgs e) { CompilePanel.Controls.Clear(); ClearResults(); m_CompileOptionsPanel = null; if (cmbLanguage.SelectedItem != null) { ILanguage l = (ILanguage)cmbLanguage.SelectedItem; CompilePanel.Controls.Add(l.OptionsPanel.Panel); m_CompileOptionsPanel = l.OptionsPanel; try { txtCode.SetHighlighting(l.Name); } catch( System.Exception ex ) { MessageBox.Show(ex.Message, "Uh-oh", MessageBoxButtons.OK, MessageBoxIcon.Error); } } }