CodeItBetter Programming Another VB Programming Blog

How to check if a given string ends with a given substring

Posted on January 4, 2009
1
2
3
4
5
6
'String Manipulation - How to check if a given string ends with a given substring
Option Explicit
 
Public Function IsEndsWith(ByVal sSource As String, ByVal sText As String) As Boolean
    IsEndsWith = (Right$(sSource, Len(sText)) = sText)
End Function
Comments (0) Trackbacks (0)

No comments yet.


Leave a comment


 

No trackbacks yet.