$ 0 0 Try this: Dim S As String = "C:\users\bmd\appdata" Dim T As String = S.Substring(S.LastIndexOf("\") + 1) MsgBox(T)