Try this one:
private void button1_Click(object sender, EventArgs e)
{
const int divider = 12;
double distance1 = double.Parse(textBox1.Text);
double distance2 = double.Parse(textBox2.Text);
double totalInches = distance1 + distance2;
double totalFeet = totalInches / divider;
MessageBox.Show("Total in inches: " + totalInches.ToString() + "Total in feet: " + totalFeet.ToString());
}
Hope you get the logic from here. Did not included data input validation anymore :)
BTW, input here is fixed for
inches you can try converting all input to inches first by creating a function that will return the converted values as inches equivalent.
Regards,
Eduard