I would like to remove comma or period and capitalize the first letter of last name
, I can only do with a textbox
which I have to insert last name
every time
Here is my code for the textbox
:
Private Sub Command2_DblClick(Cancel As Integer)
Text19 = Trim(Text19)
If Right(Text19, 1) = "." Or Right(Text19, 1) = "," Then
Text19 = Left(Text19, Len(Text19) - 1)
End If
Text19 = UCase(Left(Text19, 1)) & Mid(Text19, 2)
End Sub
How should the code be changed if I want to apply to a listbox
?