private void btnCompute_Click(object sender, EventArgs e) { typeOfHouse = comboBox1.Text; address = txtAddress.Text; number = Convert.ToInt16(txtNumber.Text); yearBuilt = Convert.ToInt32(txtYearBuilt.Text); if (rBMultyUnit.Checked == true) { MultiUnit a = new MultiUnit(number, typeOfHouse, address, yearBuilt); MessageBox.Show(a.Print()); } new Viue().Show(); }
public Viue() { InitializeComponent(); richTextBox1.Text = multiUnit.Print(); }