Below is the perfect working code, when i googled for splitting the first part of the string with a delimiter.
But i have a problem because, this code works only when the target framework is 4 How can i convert this code, where it will run in target framework 2
Public Shared Function FirstFromSplit(ByVal source As String, ByVal delimiter As String) As String
Dim i = source.IndexOf(delimiter)
Return If(i = -1, source, source.Substring(0, i))
End Function
return source.split(delimiter)?Ifexisted until .Net 4.0.