MissionPlanner.temp.BUT_QNH_Click C# (CSharp) Method

BUT_QNH_Click() private method

private BUT_QNH_Click ( object sender, EventArgs e ) : void
sender object
e EventArgs
return void
        private void BUT_QNH_Click(object sender, EventArgs e)
        {
            var currentQNH = MainV2.comPort.GetParam("GND_ABS_PRESS").ToString();

            if (InputBox.Show("QNH", "Enter the QNH in pascals (103040 = 1030.4 hPa)", ref currentQNH) ==
                DialogResult.OK)
            {
                var newQNH = double.Parse(currentQNH);

                MainV2.comPort.setParam("GND_ABS_PRESS", newQNH);
            }
        }