Is there a function to get the directory part of a file path?
so from
String a=\"/root/sdcard/Pictures/img0001.jpg\";
I have got solution on this after 4 days, Please note following points while giving path to File class in Android(Java):
mention permissions in Manifest file.
e.g.
File file=new File(path);
long=file.length();//in Bytes