2 изображение- задание номер 2Добавлено (2012-01-13, 12:17 PM)
---------------------------------------------
вообшем надо в вба сделать 2 задания, помогите плз)
Добавлено (2012-01-13, 12:31 PM)
---------------------------------------------
Private Sub CommandButton1_Click()
Dim x, y, a, b, xn, xk, dx As Single
xn = Val(TextBox1.Text)
xk = Val(TextBox2.Text)
dx = Val(TextBox3.Text)
a = Val(TextBox4.Text)
b = Val(TextBox5.Text)
x = Val(xn)
Worksheets(5).Cells(1, 10).Value = "x"
Worksheets(5).Cells(1, 11).Value = "y"
Worksheets(5).Cells(1, 12).Value = "a"
Worksheets(5).Cells(1, 13).Value = "b"
Worksheets(5).Cells(2, 12).Value = a
Worksheets(5).Cells(2, 13).Value = b
Worksheets(5).Cells(1, 14).Value = "xn"
Worksheets(5).Cells(1, 15).Value = "xk"
Worksheets(5).Cells(1, 16).Value = "dx"
Worksheets(5).Cells(2, 14).Value = xn
Worksheets(5).Cells(2, 15).Value = xk
Worksheets(5).Cells(2, 16).Value = dx
i = 2
10 Worksheets(5).Cells(i, 10).Value = x
y = (a + b) ^ (2 / 3) / e ^ a * x - 1
Worksheets(5).Cells(i, 11).Value = y
i = i + 1
x = x + dx
If x <= xk Then GoTo 10
End Sub
Private Sub CommandButton2_Click()
End
End Sub
Private Sub UserForm_Click()
End Sub
Для первой задачи так будет?