private void AssembleButton_Click(object sender, EventArgs e) { Assembler assembler; assembler = new Assembler(this); assembler.OutputMode = (AssembleToCardStrip.Checked) ? 'C' : 'M'; AssemblyResults.Text = assembler.Assemble(AssemblySource.Lines); if (AssembleToCardStrip.Checked) { InputCardsTextBox.Clear(); foreach (var line in assembler.CardList) { InputCardsTextBox.AppendText(line + "\r\n"); } } }
private void LoadCardsButton_Click(object sender, EventArgs e) { StreamReader file; String line; openFileDialog1.Filter = "Card Files (*.crd)|*.crd|All Files (*.*)|*.*"; if (openFileDialog1.ShowDialog() == DialogResult.OK) { file = new StreamReader(openFileDialog1.FileName); InputCardsTextBox.Clear(); while (!file.EndOfStream) { line = file.ReadLine(); InputCardsTextBox.AppendText(line + "\r\n"); } file.Close(); } }
private void ClearInputButton_Click(object sender, EventArgs e) { InputCardsTextBox.Clear(); }