asp.net mvc 3 - Get file name from path -
how can split path file name 1_lighthouse_20140306143834816.jpg
? , split 1_lighthouse_20140306143834816.jpg
1
reference number 1 exist.
use path.getfilename
if(countuser.length > 0) { var file = path.getfilename(countuser[0]); ....
and first character resulting string using string indexer
char firstchar = file[0]; if(firstchar == '1') ..... }
Comments
Post a Comment