Public Class Form1

 

    Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click

        Me.Close()

    End Sub

 

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click

 

        UserControl11.principle = Convert.ToDouble(Me.TextBox1.Text)

        UserControl11.intRate = Convert.ToDouble(Me.TextBox2.Text)

        UserControl11.years = Convert.ToDouble(Me.TextBox3.Text)

        UserControl11.CalculateInterest()

        Label4.Text = UserControl11.msg

    End Sub

    Private Sub ckValrate(ByVal validation As Boolean) Handles UserControl11.rate

        MessageBox.Show("Please enter the value for Interest Rate 5% or more!", "Interest Calculator Error!", MessageBoxButtons.OK, MessageBoxIcon.Asterisk, MessageBoxDefaultButton.Button1, MessageBoxOptions.DefaultDesktopOnly)

    End Sub

    Private Sub ckValpple(ByVal validation As Boolean) Handles UserControl11.pple

        MessageBox.Show("Please enter the value for Principle 100 or more!", "Interest Calculator Error!", MessageBoxButtons.OK, MessageBoxIcon.Asterisk, MessageBoxDefaultButton.Button1, MessageBoxOptions.DefaultDesktopOnly)

    End Sub

    Private Sub ckValyears(ByVal validation As Boolean) Handles UserControl11.yrs

        MessageBox.Show("Please enter the value for Years 2 or more!", "Interest Calculator Error!", MessageBoxButtons.OK, MessageBoxIcon.Asterisk, MessageBoxDefaultButton.Button1, MessageBoxOptions.DefaultDesktopOnly)

    End Sub

End Class