大虾给指导下,为什么每次运行时文本框中只显示一个数据
Private Sub Command1_Click()Dim a, b(1 To 18), i, j
a = Array(16, 16, 24, 40, 46, 74, 89, 94, 105, 129, 149, 147, 158, 190, 187, 177, 191, 203, 205, 218)
i = UBound(a) - 1
For j = 1 To i
b(j) = 0.25 * a(j - 1) + 0.5 * a(j) + 0.25 * a(j + 1)
Print b(j)
Text1.Text = b(j)
Next j
End Sub