Sub ProperFunction()
Dim strName As String
strName = Range("A1").Value
Range("B1").Value = Application.WorksheetFunction.Proper(strName)
End Sub
Sub TrimFunction()
Dim strName As String
strName = Range("A3").Value
Range("B3").Value = Trim(strName)
End Sub
Sub TrimFunction()
Dim strName As String
strName = Range("A3").Value
Range("B3").Value = Application.WorksheetFunction.Trim(strName)
End Sub
Sub SpaceFunction()
Dim strName As String
strName = Range("A1").Value
Range("B1").Value = Space(4) & strName & Space(4)
Range("C1").Value = Len(Range("A1")) & ":" & Len(Range("B1"))
End Sub
Sub ReplaceFunction()
Dim strName As String
strName = Range("A1").Value
Range("B1").Value = Replace(strName, " ", "")
End Sub
=RIGHT(A1,LEN(A1)-FIND("@",A1))
Sub RightLeftFunction()
Dim strEmail As String
strEmail = Range("A1").Value
Range("B1").Value = Right(strEmail, Len(strEmail) - InStr(strEmail, "@"))
Range("C1").Value = Left(strEmail, InStr(strEmail, "@") - 1)
End Sub
Sub MidFunction()
Dim strEmail As String
strEmail = Range("A1").Value
Range("B1").Value = Mid(strEmail, 1, InStr(strEmail, "@") - 1)
End Sub
=MID(A1,1,FIND("@",A1)-1)