G
Guest
I have this function:
Public Function FirstWord(InputString As String) As String
Dim FirstSpace As String
FirstSpace = InStr(1, InputString, " ")
FirstWord = Left(InputString, FirstSpace - 1)
End Function
This trims after the first apsce yet users are putting in spaces at the
start then this deletes the whole data.
Any suggestions on something more robust and a message that tells what data
will be deleted?
Public Function FirstWord(InputString As String) As String
Dim FirstSpace As String
FirstSpace = InStr(1, InputString, " ")
FirstWord = Left(InputString, FirstSpace - 1)
End Function
This trims after the first apsce yet users are putting in spaces at the
start then this deletes the whole data.
Any suggestions on something more robust and a message that tells what data
will be deleted?