PROGRAMAS DE VISUAL BASIC


Dim seno As Single
Dim coseno As Single
Dim tangente As Single
Dim raiz As Single

Private Sub Form_Load()
opt_seno.Value = False
opt_coseno.Value = False
opt_tangente.Value = False
opt_raiz.Value = False
End Sub

Private Sub Opt_seno_Click()
angnum = Val(txt_angnum)
angnum = 3.1416 / 180 * angnum
seno = Sin(angnum)
txt_resuavan = Round(seno, 4)
End Sub

Private Sub Opt_coseno_Click()
angnum = Val(txt_angnum)
angnum = 3.1416 / 180 * angnum
coseno = Cos(angnum)
txt_resuavan = Round(coseno, 4)
End Sub

Private Sub Opt_tangente_Click()
angnum = Val(txt_angnum)
angnum = 3.1416 / 180 * angnum
tangente = Tan(angnum)
txt_resuavan = Round(tangente, 4)
End Sub

Private Sub Opt_raiz_Click()
angnum = Val(txt_angnum)
raiz = Sqr(angnum)
txt_resuavan = Round(raiz, 4)
End Sub

No hay comentarios:

Publicar un comentario en la entrada