cmdolcet
asked on
Parsing out String
How can I parse out a string but only keep the last half of data. I only want the test1.dfq
C:\documents and settings\username\desktop\ test1.dfq
C:\documents and settings\username\desktop\
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Try this....
Dim filepath As String = "C:\documents and settings\username\desktop\test1.dfq"
Dim filename As String = filepath.Substring(filepath.LastIndexOf("\") + 1)
Hi,
try:
string path = @"C:\documents and settings\username\desktop\ test1.dfq" ;
string file = System.IO.Path.GetFileName (path);
MessageBox.Show(file);
J
try:
string path = @"C:\documents and settings\username\desktop\
string file = System.IO.Path.GetFileName
MessageBox.Show(file);
J
Hi,
sorry, in VB this would be
Dim path as String = "C:\documents and settings\username\desktop\ test1.dfq"
Dim file as String = System.IO.Path.GetFileName (path)
System.IO.Path.GetFileName (path)
J
sorry, in VB this would be
Dim path as String = "C:\documents and settings\username\desktop\
Dim file as String = System.IO.Path.GetFileName
System.IO.Path.GetFileName
J
Dim str As String
str = "C:\documents and settings\username\desktop\
str.Substring(str.LastInde