---[b]Form1.designer.vb[/b]---
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()> _
Partial Class Form1
    Inherits System.Windows.Forms.Form

    'Form overrides dispose to clean up the component list.
    <System.Diagnostics.DebuggerNonUserCode()> _
    Protected Overrides Sub Dispose(ByVal disposing As Boolean)
        If disposing AndAlso components IsNot Nothing Then
            components.Dispose()
        End If
        MyBase.Dispose(disposing)
    End Sub

    'Required by the Windows Form Designer
    Private components As System.ComponentModel.IContainer

    'NOTE: The following procedure is required by the Windows Form Designer
    'It can be modified using the Windows Form Designer.  
    'Do not modify it using the code editor.
    <System.Diagnostics.DebuggerStepThrough()> _
    Private Sub InitializeComponent()
        Me.uitkomst = New System.Windows.Forms.TextBox
        Me.Button1 = New System.Windows.Forms.Button
        Me.Button2 = New System.Windows.Forms.Button
        Me.Button3 = New System.Windows.Forms.Button
        Me.Button4 = New System.Windows.Forms.Button
        Me.Button5 = New System.Windows.Forms.Button
        Me.Button6 = New System.Windows.Forms.Button
        Me.Button7 = New System.Windows.Forms.Button
        Me.Button8 = New System.Windows.Forms.Button
        Me.Button9 = New System.Windows.Forms.Button
        Me.Button0 = New System.Windows.Forms.Button
        Me.Buttonc = New System.Windows.Forms.Button
        Me.Buttoncalc = New System.Windows.Forms.Button
        Me.Buttonplus = New System.Windows.Forms.Button
        Me.Buttonmin = New System.Windows.Forms.Button
        Me.Buttondelen = New System.Windows.Forms.Button
        Me.Buttonmaal = New System.Windows.Forms.Button
        Me.SuspendLayout()
        '
        'uitkomst
        '
        Me.uitkomst.Location = New System.Drawing.Point(29, 12)
        Me.uitkomst.Name = "uitkomst"
        Me.uitkomst.RightToLeft = System.Windows.Forms.RightToLeft.Yes
        Me.uitkomst.Size = New System.Drawing.Size(161, 20)
        Me.uitkomst.TabIndex = 60
        Me.uitkomst.TabStop = False
        Me.uitkomst.Text = "0"
        '
        'Button1
        '
        Me.Button1.Location = New System.Drawing.Point(29, 56)
        Me.Button1.Name = "Button1"
        Me.Button1.Size = New System.Drawing.Size(34, 23)
        Me.Button1.TabIndex = 0
        Me.Button1.Text = "1"
        Me.Button1.UseVisualStyleBackColor = True
        '
        'Button2
        '
        Me.Button2.Location = New System.Drawing.Point(90, 56)
        Me.Button2.Name = "Button2"
        Me.Button2.Size = New System.Drawing.Size(34, 23)
        Me.Button2.TabIndex = 2
        Me.Button2.Text = "2"
        Me.Button2.UseVisualStyleBackColor = True
        '
        'Button3
        '
        Me.Button3.Location = New System.Drawing.Point(153, 56)
        Me.Button3.Name = "Button3"
        Me.Button3.Size = New System.Drawing.Size(37, 23)
        Me.Button3.TabIndex = 3
        Me.Button3.Text = "3"
        Me.Button3.UseVisualStyleBackColor = True
        '
        'Button4
        '
        Me.Button4.Location = New System.Drawing.Point(29, 85)
        Me.Button4.Name = "Button4"
        Me.Button4.Size = New System.Drawing.Size(34, 23)
        Me.Button4.TabIndex = 4
        Me.Button4.Text = "4"
        Me.Button4.UseVisualStyleBackColor = True
        '
        'Button5
        '
        Me.Button5.Location = New System.Drawing.Point(90, 85)
        Me.Button5.Name = "Button5"
        Me.Button5.Size = New System.Drawing.Size(34, 23)
        Me.Button5.TabIndex = 5
        Me.Button5.Text = "5"
        Me.Button5.UseVisualStyleBackColor = True
        '
        'Button6
        '
        Me.Button6.Location = New System.Drawing.Point(153, 85)
        Me.Button6.Name = "Button6"
        Me.Button6.Size = New System.Drawing.Size(37, 23)
        Me.Button6.TabIndex = 6
        Me.Button6.Text = "6"
        Me.Button6.UseVisualStyleBackColor = True
        '
        'Button7
        '
        Me.Button7.Location = New System.Drawing.Point(29, 114)
        Me.Button7.Name = "Button7"
        Me.Button7.Size = New System.Drawing.Size(34, 23)
        Me.Button7.TabIndex = 7
        Me.Button7.Text = "7"
        Me.Button7.UseVisualStyleBackColor = True
        '
        'Button8
        '
        Me.Button8.Location = New System.Drawing.Point(90, 114)
        Me.Button8.Name = "Button8"
        Me.Button8.Size = New System.Drawing.Size(34, 23)
        Me.Button8.TabIndex = 8
        Me.Button8.Text = "8"
        Me.Button8.UseVisualStyleBackColor = True
        '
        'Button9
        '
        Me.Button9.Location = New System.Drawing.Point(153, 114)
        Me.Button9.Name = "Button9"
        Me.Button9.Size = New System.Drawing.Size(37, 23)
        Me.Button9.TabIndex = 9
        Me.Button9.Text = "9"
        Me.Button9.UseVisualStyleBackColor = True
        '
        'Button0
        '
        Me.Button0.Location = New System.Drawing.Point(90, 143)
        Me.Button0.Name = "Button0"
        Me.Button0.Size = New System.Drawing.Size(34, 23)
        Me.Button0.TabIndex = 10
        Me.Button0.Text = "0"
        Me.Button0.UseVisualStyleBackColor = True
        '
        'Buttonc
        '
        Me.Buttonc.Location = New System.Drawing.Point(29, 143)
        Me.Buttonc.Name = "Buttonc"
        Me.Buttonc.Size = New System.Drawing.Size(34, 23)
        Me.Buttonc.TabIndex = 11
        Me.Buttonc.Text = "C"
        Me.Buttonc.UseVisualStyleBackColor = True
        '
        'Buttoncalc
        '
        Me.Buttoncalc.Location = New System.Drawing.Point(153, 143)
        Me.Buttoncalc.Name = "Buttoncalc"
        Me.Buttoncalc.Size = New System.Drawing.Size(37, 23)
        Me.Buttoncalc.TabIndex = 12
        Me.Buttoncalc.Text = "="
        Me.Buttoncalc.UseVisualStyleBackColor = True
        '
        'Buttonplus
        '
        Me.Buttonplus.Location = New System.Drawing.Point(12, 172)
        Me.Buttonplus.Name = "Buttonplus"
        Me.Buttonplus.Size = New System.Drawing.Size(36, 23)
        Me.Buttonplus.TabIndex = 13
        Me.Buttonplus.Text = "+"
        Me.Buttonplus.UseVisualStyleBackColor = True
        '
        'Buttonmin
        '
        Me.Buttonmin.Location = New System.Drawing.Point(69, 172)
        Me.Buttonmin.Name = "Buttonmin"
        Me.Buttonmin.Size = New System.Drawing.Size(36, 23)
        Me.Buttonmin.TabIndex = 14
        Me.Buttonmin.Text = "-"
        Me.Buttonmin.UseVisualStyleBackColor = True
        '
        'Buttondelen
        '
        Me.Buttondelen.Location = New System.Drawing.Point(121, 172)
        Me.Buttondelen.Name = "Buttondelen"
        Me.Buttondelen.Size = New System.Drawing.Size(40, 23)
        Me.Buttondelen.TabIndex = 15
        Me.Buttondelen.Text = "/"
        Me.Buttondelen.UseVisualStyleBackColor = True
        '
        'Buttonmaal
        '
        Me.Buttonmaal.Location = New System.Drawing.Point(177, 172)
        Me.Buttonmaal.Name = "Buttonmaal"
        Me.Buttonmaal.Size = New System.Drawing.Size(36, 23)
        Me.Buttonmaal.TabIndex = 16
        Me.Buttonmaal.Text = "*"
        Me.Buttonmaal.UseVisualStyleBackColor = True
        '
        'Form1
        '
        Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
        Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
        Me.ClientSize = New System.Drawing.Size(225, 203)
        Me.Controls.Add(Me.Buttonmaal)
        Me.Controls.Add(Me.Buttondelen)
        Me.Controls.Add(Me.Buttonmin)
        Me.Controls.Add(Me.Buttonplus)
        Me.Controls.Add(Me.Buttoncalc)
        Me.Controls.Add(Me.Buttonc)
        Me.Controls.Add(Me.Button0)
        Me.Controls.Add(Me.Button9)
        Me.Controls.Add(Me.Button8)
        Me.Controls.Add(Me.Button7)
        Me.Controls.Add(Me.Button6)
        Me.Controls.Add(Me.Button5)
        Me.Controls.Add(Me.Button4)
        Me.Controls.Add(Me.Button3)
        Me.Controls.Add(Me.Button2)
        Me.Controls.Add(Me.Button1)
        Me.Controls.Add(Me.uitkomst)
        Me.MaximizeBox = False
        Me.MinimizeBox = False
        Me.Name = "Form1"
        Me.Text = "Rekenmachine"
        Me.ResumeLayout(False)
        Me.PerformLayout()

    End Sub
    Friend WithEvents uitkomst As System.Windows.Forms.TextBox
    Friend WithEvents Button1 As System.Windows.Forms.Button
    Friend WithEvents Button2 As System.Windows.Forms.Button
    Friend WithEvents Button3 As System.Windows.Forms.Button
    Friend WithEvents Button4 As System.Windows.Forms.Button
    Friend WithEvents Button5 As System.Windows.Forms.Button
    Friend WithEvents Button6 As System.Windows.Forms.Button
    Friend WithEvents Button7 As System.Windows.Forms.Button
    Friend WithEvents Button8 As System.Windows.Forms.Button
    Friend WithEvents Button9 As System.Windows.Forms.Button
    Friend WithEvents Button0 As System.Windows.Forms.Button
    Friend WithEvents Buttonc As System.Windows.Forms.Button
    Friend WithEvents Buttoncalc As System.Windows.Forms.Button
    Friend WithEvents Buttonplus As System.Windows.Forms.Button
    Friend WithEvents Buttonmin As System.Windows.Forms.Button
    Friend WithEvents Buttondelen As System.Windows.Forms.Button
    Friend WithEvents Buttonmaal As System.Windows.Forms.Button

End Class

---[b]Form1.vb[/b]---
Public Class Form1
    'Variabelen setten'
    Dim waarde1 As Integer
    Dim waarde2 As Integer
    Dim oper As String
    Dim uitkomst2 As Integer
    'De buttons'
    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
        If Val(uitkomst.Text) = 0 Then
            uitkomst.Text = Button1.Text
        Else : uitkomst.Text &= Button1.Text
        End If
    End Sub
    Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
        If Val(uitkomst.Text) = 0 Then
            uitkomst.Text = Button2.Text
        Else : uitkomst.Text &= Button2.Text
        End If
    End Sub
    Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click
        If Val(uitkomst.Text) = 0 Then
            uitkomst.Text = Button3.Text
        Else : uitkomst.Text &= Button3.Text
        End If
    End Sub
    Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click
        If Val(uitkomst.Text) = 0 Then
            uitkomst.Text = Button4.Text
        Else : uitkomst.Text &= Button4.Text
        End If
    End Sub
    Private Sub Button5_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button5.Click
        If Val(uitkomst.Text) = 0 Then
            uitkomst.Text = Button5.Text
        Else : uitkomst.Text &= Button5.Text
        End If
    End Sub
    Private Sub Button6_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button6.Click
        If Val(uitkomst.Text) = 0 Then
            uitkomst.Text = Button6.Text
        Else : uitkomst.Text &= Button6.Text
        End If
    End Sub
    Private Sub Button7_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button7.Click
        If Val(uitkomst.Text) = 0 Then
            uitkomst.Text = Button7.Text
        Else : uitkomst.Text &= Button7.Text
        End If
    End Sub
    Private Sub Button8_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button8.Click
        If Val(uitkomst.Text) = 0 Then
            uitkomst.Text = Button8.Text
        Else : uitkomst.Text &= Button8.Text
        End If
    End Sub
    Private Sub Button9_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button9.Click
        If Val(uitkomst.Text) = 0 Then
            uitkomst.Text = Button9.Text
        Else : uitkomst.Text &= Button9.Text
        End If
    End Sub
    Private Sub Button0_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button0.Click
        If Val(uitkomst.Text) = 0 Then
            uitkomst.Text = Button0.Text
        Else : uitkomst.Text &= Button0.Text
        End If
    End Sub

    Private Sub Buttonplus_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Buttonplus.Click
        waarde1 = Val(uitkomst.Text)
        uitkomst.Text = "0"
        oper = "plus"
    End Sub

    Private Sub Buttonmin_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Buttonmin.Click
        waarde1 = Val(uitkomst.Text)
        uitkomst.Text = "0"
        oper = "min"
    End Sub

    Private Sub Buttondelen_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Buttondelen.Click
        waarde1 = Val(uitkomst.Text)
        uitkomst.Text = "0"
        oper = "delen"
    End Sub

    Private Sub Buttonmaal_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Buttonmaal.Click
        waarde1 = Val(uitkomst.Text)
        uitkomst.Text = "0"
        oper = "maal"
    End Sub

    Private Sub Buttonc_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Buttonc.Click
        waarde1 = 0
        waarde2 = 0
        oper = ""
        uitkomst.Text = "0"
    End Sub

    Private Sub Buttoncalc_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Buttoncalc.Click
        waarde2 = Val(uitkomst.Text)
        If oper = "plus" Then
            uitkomst2 = waarde1 + waarde2
        End If
        If oper = "min" Then
            uitkomst2 = waarde1 - waarde2
        End If
        If oper = "delen" Then
            uitkomst2 = waarde1 / waarde2
        End If
        If oper = "maal" Then
            uitkomst2 = waarde1 * waarde2
        End If
        uitkomst.Text = uitkomst2
    End Sub

    Private Sub uitkomst_GotFocus(ByVal sender As Object, ByVal e As System.EventArgs) Handles uitkomst.GotFocus
        Buttonc.Focus()
    End Sub

End Class[b][/b] 