Author: Unknown Genre:
    Rating

     Public Class Form1

        Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
            Dim x, nilai As Integer
            nilai = CInt(TextBox1.Text)
            For x = 1 To nilai
                If x Mod 2 <> 0 Then
                    ListBox1.Items.Add(x)
                End If
            Next
        End Sub

        Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
            Dim x, y, nilai As Integer
            nilai = CInt(TextBox1.Text)
            For x = 1 To nilai
                If x Mod 2 = 0 Then
                    ListBox1.Items.Add(x)
                End If
            Next
        End Sub

    End Class

    Leave a Reply

    Blogger templates

    http://btemplates.com/2011/blogger-template-box-office/demo/

    Blogger news

    Blogroll