c# - How to grab name of a streamreader -


in c#, how grab name or path of streamreader

ie

filein = new streamreader(@"c:\ee\fff\desktop\spreadtool\test.csv"); 

and want regex on path, how reference above. know filestreamer has getname() method streamreader? looked , doesn't seem have one.

streamreader not have property contains filepath created. may not created file @ (it can created stream). if want path, should store in string before create streamreader

string file = @"c:\ee\ccc\desktop\spreadtool\test.csv" filein = new streamreader(file); string path = path.getdirectory(file); 

Comments

Popular posts from this blog

php - Calling a template part from a post -

Firefox SVG shape not printing when it has stroke -

How to mention the localhost in android -