trim local path when retrieve a file
hi i need a help,in c# windows application how to trim the local path.(ex:c:\user\newfolder\test.txt) i want to trim this
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Jignesh TrivediPosted Apr 23, 2014, 8:14 AM
actually I am not getting your question.
Vasu GadhiyaPosted Apr 23, 2014, 6:58 AM
if you want to remove White space from string than you can use use trim mathod.
like
string temp = " csharpcorner";
temp.Trim();
-----
now temp = "csharpcorner"
VulpesPosted Apr 23, 2014, 6:54 AM
System.IO.Path.GetFileName(fullPath)