private void nIntegrity_ValueChanged(object sender, EventArgs e) { NumericUpDown nud; nud = (NumericUpDown)sender; map.ChangeIntegrity(Convert.ToInt32(nud.Value)); }