Question: What is the solution to question #23E in chapter 10 of the text book Microsoft Visual Basic 2015 Reloaded (sixth edition). The following is the
What is the solution to question #23E in chapter 10 of the text book Microsoft Visual Basic 2015 Reloaded (sixth edition). The following is the code that is suppplied and a picture of the mainform.
' Project name: Date Project ' Project purpose: Verifies a date's format and changes the year number from "yy" to "20yy" ' Created/revised by:
Option Explicit On Option Strict On Option Infer Off
Public Class MainForm Private Sub exitButton_Click(sender As Object, e As EventArgs) Handles exitButton.Click Me.Close() End Sub
Private Sub dateTextBox_Enter(sender As Object, e As EventArgs) Handles dateTextBox.Enter dateTextBox.SelectAll() End Sub
Private Sub dateTextBox_KeyPress(sender As Object, e As KeyPressEventArgs) Handles dateTextBox.KeyPress ' allows only numbers, the slash, and the Backspace key
If (e.KeyChar "9") AndAlso e.KeyChar "/" AndAlso e.KeyChar ControlChars.Back Then e.Handled = True End If End Sub End Class

Date Date (mm/dd/yy): Date (mm/dd/yyyy): Display Date Exit
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
