'我在VB环境里,好像有问题,没编译执行.你看着办吧.
Option Explicit
Const a As Double = 1350600# '1.3506*10^6
Const b As Double = 38.6417
Const R As Double = 82.06
Private Sub Command1_Click()
Dim P As Double
Dim T As Double
Dim V As Double
If IsNumeric(Text1.Text) And IsNumeric(Text2.Text) Then
P = Val(Text1.Text)
T = Val(Text2.Text)
V = (R * T) / (P + a / (V * V)) + b
MsgBox V
'text3.Text = V
Else
MsgBox "请输入 P 和 T 的值."
End If
End Sub