/**Get the material velocity of current rows selected.*/ private void materialList_CellClick(object sender, DataGridViewCellEventArgs e) { string velocity = materialList.Rows[materialList.CurrentRow.Index] .Cells["Velocity"].Value.ToString(); numUpDownMatVelocity.Text = velocity; SetMaterialVelocityDAQ.Velocity(SelectAscan.sessionIndex, SelectAscan.port, Convert.ToDouble(velocity)); }
private void numUpDownMatVelocity_KeyPress(object sender, KeyPressEventArgs e) { double velocity = Convert.ToDouble(numUpDownMatVelocity.Value); judgeNumUpDownInput(numUpDownMatVelocity, e); if (e.KeyChar == (char)Keys.Enter) { SetMaterialVelocityDAQ.Velocity(SelectAscan.sessionIndex, SelectAscan.port, velocity); } }
private void numUpDownMatVelocity_Leave(object sender, EventArgs e) { double velocity = Convert.ToDouble(numUpDownMatVelocity.Value); SetMaterialVelocityDAQ.Velocity(SelectAscan.sessionIndex, SelectAscan.port, velocity); }