黑客24小时在线接单网站

诚信黑客,黑客接单平台,专业黑客在线接单,信誉黑客接单,黑客高手

压接单位在线转换器(单位在线转换器单位换算器)

本文导读目录:

压力单位换算

1bar=10^5pa

1MPa=10bar=1000KPa=10^6pa

公斤和斤是质量单位,其他是压强单位,

欧姆龙血压计单位转换(在线等)

请问你用的是那个型号的血压计?一般的切换方法是,开机时持续按住开关5秒以上,则可转换显示单位,并自动保存此设置,以后正常开机使用时,都是以此单位值显示

VB单位转换器怎样做

刚才有个人提了一个类似的问题(cm m km的转换),不过他是要求只在一个text和combo中实现的,比你的要求更严格,你看看,要转换成两个的也很方便的:

Private Sub Combo1_Click()

If IsNumeric(Text1.Text) Then Text1.Text = Val(Text1.Text) / Val(Text1.Tag) * Combo1.ItemData(Combo1.ListIndex)

Text1.Tag = CStr(Combo1.ItemData(Combo1.ListIndex))

End Sub

Private Sub Form_Load()

Text1.Tag = "1000"

Text1.Text = ""

Combo1.Clear

Combo1.AddItem "cm"

Combo1.ItemData(Combo1.NewIndex) = 100000

Combo1.AddItem "m"

Combo1.ItemData(Combo1.NewIndex) = 1000

Combo1.AddItem "km"

Combo1.ItemData(Combo1.NewIndex) = 1

Combo1.ListIndex = 1

End Sub

数学单位转换

1千克=1000克 1吨=1000千克

1公顷=10000平方米 1平方千米=1000平方米

1立方米=1000立方分米 1立方分米=1000立方厘米 1立方厘米=1立方毫米

1升=1000毫升=1立方分米=1000平方厘米 1毫升=1立方厘米

压力单位MPa/psi/bar之间的换算?

工程上常用的是兆帕(MPa):1MPa=1000000Pa.

1个标准大气压力=1.00336×0.098MPa=0.10108MPa≈0.1Mpa.

1bar=0.1MPa

压力的法定单位是帕斯卡(Pa):1Pa=1N/㎡(牛顿/平方米).

压力单位换算:

1MPa=1000kPa

1kPa=10mbar=101.9716 mmH2O = 4.01463imH2O

10mWC=1bar=100kPa

bar 巴 = 0.987 大气压 = 1.02 千克/平方厘米 = 100 千帕 = 14.5 磅/平方英寸

PSI英文全称为Pounds per square inch.P是磅pound,S是平方square,I是英寸inch.把所有的单位换成公制单位就可以算出:1bar≈14.5psi

1psi=6.895kPa=0.06895bar

1兆帕(MPa)=145磅/英寸2(psi)=10.2千克/厘米2(kg/cm2)=10巴(bar)=9.8大气压(atm)

1磅/英寸2(psi)=0.006895兆帕(MPa)=0.0703千克/厘米2(kg/cm2)=0.0689巴(bar)=0.068大气压(atm)

1巴(bar)=0.1兆帕(MPa)=14.503磅/英寸2(psi)=1.0197千克/厘米2(kg/cm2)=0.987大气压(atm)

1大气压(atm)=0.101325兆帕(MPa)=14.696磅/英寸2(psi)=1.0333千克/厘米2(kg/cm2)=1.0133巴(bar)

数据单位转换工具java代码

import javax.swing.*;

import javax.swing.event.*;

import java.awt.*;

import java.awt.event.*;

public class UnitTransfer extends JFrame{

    private final int WIDTH = 400, HEIGHT = 300;//窗口默认的宽度、高度

    

    private JLabel lblInUnit=new JLabel("输入单位");

    private JComboBox cboIn=new JComboBox(new String[]{"", ""});

    private JLabel lblIn=new JLabel("输入数值");

    private JTextField txtIn=new JTextField("10");

    

    private JLabel lblOutUnit=new JLabel("输出单位");

    private JLabel lblResult=new JLabel("显示结果");

    private JLabel txtResult=new JLabel("结果");

    private JComboBox cboOut=new JComboBox(new String[]{"", ""});

    

    private JButton btnTrans = new JButton("转换");

    private JButton btnClear = new JButton("清空");

    

    private JRadioButton rdLeng = new JRadioButton("长度");

    private JRadioButton rdWeig = new JRadioButton("时间");

    private String [] lengthUnit={"米", "分米", "厘米", "毫米"};

    private String [] timeUnit={"天", "时", "分", "秒"};

    

    public UnitTransfer(){

        super("简单的单位转换器 Beta");

        this.setSize(WIDTH, HEIGHT);

        this.setLayout(null);

        this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);

        

        ButtonGroup group = new ButtonGroup();

        group.add(rdLeng);

        group.add(rdWeig);

        this.getContentPane().add(rdLeng);

        this.getContentPane().add(rdWeig);

        this.getContentPane().add(btnTrans);

        this.getContentPane().add(btnClear);

        this.getContentPane().add(lblIn);

        this.getContentPane().add(txtIn);

        this.getContentPane().add(lblInUnit);

        this.getContentPane().add(cboIn);

        this.getContentPane().add(lblResult);

        this.getContentPane().add(txtResult);

        this.getContentPane().add(lblOutUnit);

        this.getContentPane().add(cboOut);

        this.setVisible(true);

        this.doLayout();

        btnTrans.addActionListener(new ActionListener(){

            public void actionPerformed(ActionEvent e){

                doConvert();

            }

        });

        btnClear.addActionListener(new ActionListener(){

            public void actionPerformed(ActionEvent e){

                txtIn.setText("0");

                txtResult.setText("0");

            }

        });

        rdLeng.addActionListener(new ActionListener(){

            public void actionPerformed(ActionEvent e){

                cboIn.setModel(new DefaultComboBoxModel(lengthUnit));

                cboOut.setModel(new DefaultComboBoxModel(lengthUnit));

            }

        });

        rdWeig.addActionListener(new ActionListener(){

            public void actionPerformed(ActionEvent e){

                cboIn.setModel(new DefaultComboBoxModel(timeUnit));

                cboOut.setModel(new DefaultComboBoxModel(timeUnit));

            }

        });

        rdLeng.setSelected(true);

        cboIn.setModel(new DefaultComboBoxModel(lengthUnit));

        cboOut.setModel(new DefaultComboBoxModel(timeUnit));

    }

    final int offX=100;

    public void doLayout(){

        super.doLayout();

        

        rdLeng.setBounds(offX, 15, 60, 20);

        rdWeig.setBounds(rdLeng.getX()+rdLeng.getWidth()+5, 15, 60, 20);

        

        lblInUnit.setBounds(offX, rdLeng.getY()+rdLeng.getHeight()+20, 80, 20);

        cboIn.setBounds(lblInUnit.getX()+lblInUnit.getWidth()+5, lblInUnit.getY(), 80, 20);

        lblIn.setBounds(offX, lblInUnit.getY()+lblInUnit.getHeight()+5, 80, 20);

        txtIn.setBounds(lblIn.getX()+lblIn.getWidth()+5, lblIn.getY(), 80, 20);

        

        lblOutUnit.setBounds(offX, lblIn.getY()+lblIn.getHeight()+30, 80, 20);

        cboOut.setBounds(lblOutUnit.getX()+lblOutUnit.getWidth()+5, lblOutUnit.getY(), 80, 20);

        lblResult.setBounds(offX, cboOut.getY()+cboOut.getHeight()+5, 80, 20);

        txtResult.setBounds(lblResult.getX()+lblResult.getWidth()+5, lblResult.getY(), 100, 20);

        

        int w=getWidth ();

        int x=(w-70*2-5)/2;//水平居中

        btnTrans.setBounds(x, lblResult.getY()+lblResult.getHeight()+30, 70, 25);

        btnClear.setBounds(btnTrans.getX()+btnTrans.getWidth()+3, btnTrans.getY(), 70, 25);

    }

    public void doConvert(){

        double v=0;

        try{

            v= Double.parseDouble(txtIn.getText());

        }catch(Exception ex){

            txtIn.setText("0");

            return;

        }

        //"米", "分米", "厘米", "毫米"

        if(rdLeng.isSelected()){

            switch(cboIn.getSelectedIndex()){

                case 0:

                    break;

                case 1:

                    v=v/10;

                    break;

                case 2:

                    v=v/100;

                    break;

                case 3:

                    v=v/1000;

                    break;

                default:

                    return;

            }

            //v 现在是标准单位:米

            switch(cboOut.getSelectedIndex()){

                case 0:

                    break;

                case 1:

                    v=v*10;

                    break;

                case 2:

                    v=v*100;

                    break;

                case 3:

                    v=v*1000;

                    break;

                default:

                    return;

            }

            if(v0.01){

                txtResult.setText(String.format("%2.8f", v));

            }else{

                txtResult.setText(String.format("%2.2f", v));

            }

        }else{

        //"天", "时", "分", "秒"

            switch(cboIn.getSelectedIndex()){

                case 0:

                    v=v*24;

                    break;

                case 1:

                    break;

                case 2:

                    v=v/60;

                    break;

                case 3:

                    v=v/3600;

                    break;

                default:

                    return;

            }

            //v 现在是标准单位:小时

            switch(cboOut.getSelectedIndex()){

                case 0:

                    v=v/24;

                    break;

                case 1:

                    break;

                case 2:

                    v=v*60;

                    break;

                case 3:

                    v=v*3600;

                    break;

                default:

                    return;

            }

            if(v0.01){

                txtResult.setText(String.format("%2.8f", v));

            }else{

                txtResult.setText(String.format("%2.8f", v));

            }

        }

    }

    

    public static void main(String[] args){

        EventQueue.invokeLater(new Runnable()  {

            public void run()   {

                new UnitTransfer();

            }

        });

    }

}

//请参考,欢迎指正

  • 评论列表:
  •  黑客技术
     发布于 2022-06-02 07:16:12  回复该评论
  • ate JButton btnTrans = new JButton("转换");    private JButton btnClear = new JButton(
  •  黑客技术
     发布于 2022-06-02 06:13:17  回复该评论
  • f(v0.01){                txtResult.setText(String.format("%2.8f", v));            }else{                txtResult.setText(String.format(
  •  黑客技术
     发布于 2022-06-02 08:55:37  回复该评论
  •            switch(cboIn.getSelectedIndex()){                case 0:                    break;                case 1:

发表评论:

Powered By

Copyright Your WebSite.Some Rights Reserved.