Dim a As Currency, b As Currency, c As Currency, d As Currency, e As Currency, p *也可用@定义数据类型,例如:a@
a = Val(Text1.Text) *a被赋予Text1中的数值
b = Val(Text2.Text) *b被赋予Text2中的数值
c = Val(Text3.Text) *c被赋予Text3中的数值
d = Val(Text4.Text) *d被赋予Text4中的数值
e = ((c * b) / (a * d)) * 100 *对e进行计算
Text5 = Format(e, "0.####") *将e的值显示到Text5,并保留4位小数
End If
End Sub
a = Val(Text1.Text) *a被赋予Text1中的数值
b = Val(Text2.Text) *b被赋予Text2中的数值
c = Val(Text3.Text) *c被赋予Text3中的数值
d = Val(Text4.Text) *d被赋予Text4中的数值
e = ((c * b) / (a * d)) * 100 *对e进行计算
Text5 = Format(e, "0.####") *将e的值显示到Text5,并保留4位小数
End If
End Sub