phpcms用的什么框架:vba的问题 帮忙解释一下

来源:百度文库 编辑:杭州交通信息网 时间:2024/04/28 04:31:13
Private Sub CommandButton1_Click()
Dim ss(1 To 6) As String
Dim kk(1 To 6) As Double

ss(1) = UserForm1.TextBox1.text
ss(2) = UserForm1.TextBox2.text
ss(3) = UserForm1.TextBox3.text
ss(4) = UserForm1.TextBox4.text
ss(5) = UserForm1.TextBox5.text
ss(6) = UserForm1.TextBox6.text
For i = 1 To 6
If ss(i) = "" Then
ss(i) = "0"
End If
kk(i) = jx(ss(i))
If kk(i) = -1 Then
MsgBox "公式有错误,请核对"
UserForm1.TextBox1.SetFocus
Exit Sub
End If
Next i
UserForm1.TextBox9.text = Str(qw(kk(1)))
UserForm1.TextBox10.text = Str(qw(kk(2)))
UserForm1.TextBox11.text = Str(qw(kk(3)))
UserForm1.TextBox12.text = Str(qw(kk(4)))
UserForm1.TextBox13.text = Str(qw(kk(5)))
UserForm1.TextBox14.text = Str(qw(kk(6)))
res = qw(kk(1) + kk(2) + kk(3) + kk(4) + kk(5) + kk(6))
UserForm1.TextBox15.text = Str(res)

Dim xx As Double
Dim yy As Double
Dim hh As Double

xx = 37411
yy = -22550
hh = 480

If UserForm1.TextBox1.text <> "" Then
Call textstring(UserForm1.TextBox1.text + "=" + find(Trim(UserForm1.TextBox9.text)), xx, yy, hh, "_simplex")
End If
If UserForm1.TextBox2.text <> "" Then
Call textstring(UserForm1.TextBox2.text + "=" + find(Trim(UserForm1.TextBox10.text)), xx, (yy - 1200), hh, "_simplex")
End If
If UserForm1.TextBox3.text <> "" Then
Call textstring(UserForm1.TextBox3.text + "=" + find(Trim(UserForm1.TextBox11.text)), xx, (yy - 2400), hh, "_simplex")
End If
If UserForm1.TextBox4.text <> "" Then
Call textstring(UserForm1.TextBox4.text + "=" + find(Trim(UserForm1.TextBox12.text)), xx, (yy - 3600), hh, "_simplex")
End If
If UserForm1.TextBox5.text <> "" Then
Call textstring(UserForm1.TextBox5.text + "=" + find(Trim(UserForm1.TextBox13.text)), xx, (yy - 4800), hh, "_simplex")
End If
If UserForm1.TextBox6.text <> "" Then
Call textstring(UserForm1.TextBox6.text + "=" + find(Trim(UserForm1.TextBox14.text)), xx, (yy - 6000), hh, "_simplex")
End If
If UserForm1.TextBox15.text <> "0" Then
Call textstring(find(Trim(UserForm1.TextBox15.text)), 38844, -28870, 480, "_simplex")
End If

End Sub

Private Sub CommandButton3_Click()
Unload UserForm1
Exit Sub
End Sub

哇,这么长。

硬着头皮大体看了一眼,

很简单。

可惜我不知道jx函数、textstring过程是干什么用的。

你没有写出来