Hjnfgyjngfjn

Páginas: 4 (763 palabras) Publicado: 1 de julio de 2012
Dim x As Integer
For x = 1 To 100
ListBox1.Items.Add(x)
Next

FUNCIONES MATEMATICAS
Funciones de fecha
TextBox1.Text = Now
TextBox2.Text = Date.NowTextBox3.Text = Year(Now)
TextBox4.Text = Month(Now)
TextBox5.Text = MonthName(Month(Date.Now), False)
TextBox6.Text = Day.Default
TextBox7.Text = TimeOfDayTextBox8.Text = Hour(TimeOfDay)
TextBox9.Text = Minute(TimeOfDay)
TextBox10.Text = Second(TimeOfDay)
TextBox11.Text = WeekdayName(Weekday(Date.Now), False)TextBox2.Text = Math.Abs(Val(TextBox1.Text))
TextBox3.Text = Math.Sqrt(Val(TextBox1.Text))
TextBox4.Text = Math.Round(Val(TextBox1.Text))
TextBox5.Text =Math.Sin(Val(TextBox1.Text) * Math.PI / 180)
TextBox6.Text = Math.Tan(Val(TextBox1.Text) * Math.PI / 180)
TextBox7.Text = 1 / Math.Tan(Val(TextBox1.Text) * Math.PI / 180)



ARRAY O LISTA(unidemencional)
Dim a(3), b(3), x As Integer
a(0) = 10
a(1) = 20
a(2) = 30
a(3) = 40
b(0) = 1
b(1) = 2
b(2) = 3
b(3) = 4For x = 0 To a.Length() - 1
ListBox1.Items.Add(a(x))
ListBox1.Items.Add(b(x))

ublic Class Form1
Dim n, x As Integer
Dim B(100) As Integer
Private SubButton1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
n = TextBox1.Text
For x = 1 To n
B(x) = InputBox("ingrese numero rn laposccion" & Str(x))

Next
End Sub

Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
ListBox1.Items.Clear()For x = 1 To n + 1

If B(x) <> 0 Then
ListBox1.Items.Add(B(x))
End If
Next
End Sub

Private Sub Form1_Load(ByVal sender As...
Leer documento completo

Regístrate para leer el documento completo.

Conviértase en miembro formal de Buenas Tareas

INSCRÍBETE - ES GRATIS