VB中提示溢出什么意思,我已经定义i,j,k为double,怎么还是提示溢出Private Sub Command1_Click()n = a + b + cp = d + e + fq = h - gu = (q - n) * (-1) * 1000i = u * d / pj = u * e / pk = u * f / px = CInt(i)y = CInt(j)z = CInt(k)l = d

来源:学生作业帮助网 编辑:六六作业网 时间:2024/11/14 15:05:11
VB中提示溢出什么意思,我已经定义i,j,k为double,怎么还是提示溢出PrivateSubCommand1_Click()n=a+b+cp=d+e+fq=h-gu=(q-n)*(-1)*1000

VB中提示溢出什么意思,我已经定义i,j,k为double,怎么还是提示溢出Private Sub Command1_Click()n = a + b + cp = d + e + fq = h - gu = (q - n) * (-1) * 1000i = u * d / pj = u * e / pk = u * f / px = CInt(i)y = CInt(j)z = CInt(k)l = d
VB中提示溢出什么意思,我已经定义i,j,k为double,怎么还是提示溢出
Private Sub Command1_Click()
n = a + b + c
p = d + e + f
q = h - g
u = (q - n) * (-1) * 1000
i = u * d / p
j = u * e / p
k = u * f / p
x = CInt(i)
y = CInt(j)
z = CInt(k)
l = d + x / 1000
m = e + y / 1000
o = f + z / 1000
r = h + l
s = r + m
Text7.Text = Str(x)
Text8.Text = Str(y)
Text9.Text = Str(z)
Text10.Text = Str(l)
Text11.Text = Str(m)
Text12.Text = Str(o)
Text14.Text = Str(r)
Text15.Text = Str(s)

VB中提示溢出什么意思,我已经定义i,j,k为double,怎么还是提示溢出Private Sub Command1_Click()n = a + b + cp = d + e + fq = h - gu = (q - n) * (-1) * 1000i = u * d / pj = u * e / pk = u * f / px = CInt(i)y = CInt(j)z = CInt(k)l = d
是哪一行提示溢出呢?有多种原因造成溢出的,比如
x = CInt(i)
如果i超出Integer的范围(-32768到32767)那么CInt(i)就会溢出,可改为:
x = Int(i)