I'm trying to create an input mask using VBA. The input mask needs to have two possible variations based on the entry in another field. I was able to find some VBA code that is supposed to solve the problem, but it doesn't. The code I have only shows the input mask of the Else condition. Could someone look at it for me and give suggestions. Thank you.
Private Sub Tax_ID_Number_AfterUpdate()
If Me.Tax_ID_Number_Type = "Employer Identification Number (EIN)" Then
Me.Tax_ID_Number.InputMask = "00-0000000"
Else
Me.Tax_ID_Number.InputMask = "000-00-0000"
End If
Private Sub Tax_ID_Number_AfterUpdate()
If Me.Tax_ID_Number_Type = "Employer Identification Number (EIN)" Then
Me.Tax_ID_Number.InputMask = "00-0000000"
Else
Me.Tax_ID_Number.InputMask = "000-00-0000"
End If