Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Private Sub btnent_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnent.Click
- 'ensures a number that ends with 0 or 5 can only be entered into the text box'
- If txtAmount.Text >= myaccount Then MessageBox.Show("You have insufficient funds to make that transaction")
- If txtAmount.Text >= danaccount Then MessageBox.Show("You have insufficient funds to make that transaction")
- If txtAmount.Text >= lewisaccount Then MessageBox.Show("You have insufficient funds to make that transaction")
- If txtAmount.Text >= 501 Then MessageBox.Show("enter amount equal or less than £500 please")
- txtAmount.Clear()
- If txtAmount.Text.EndsWith(1) Then
- MsgBox("Number does not end in 0 or 5!")
- txtAmount.Clear()
- ElseIf txtAmount.Text.EndsWith(2) Then
- MsgBox("Number does not end in 0 or 5!")
- txtAmount.Clear()
- ElseIf txtAmount.Text.EndsWith(3) Then
- MsgBox("Number does not end in 0 or 5!")
- txtAmount.Clear()
- ElseIf txtAmount.Text.EndsWith(4) Then
- MsgBox("Number does not end in 0 or 5!")
- txtAmount.Clear()
- ElseIf txtAmount.Text.EndsWith(6) Then
- MsgBox("Number does not end in 0 or 5!")
- txtAmount.Clear()
- ElseIf txtAmount.Text.EndsWith(7) Then
- MsgBox("Number does not end in 0 or 5!")
- txtAmount.Clear()
- ElseIf txtAmount.Text.EndsWith(8) Then
- MsgBox("Number does not end in 0 or 5!")
- txtAmount.Clear()
- ElseIf txtAmount.Text.EndsWith(9) Then
- MsgBox("Number does not end in 0 or 5!")
- txtAmount.Clear()
- End If
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement