×

Welcome to TagMyCode

Please login or create account to add a snippet.
0
0
 
0
Language: Java
Posted by: Hani Ibrahim
Added: Dec 31, 2016 12:26 AM
Modified: Dec 31, 2016 12:31 AM
Views: 6
Extract filename without extention from path
/home/user/test.txt => test
  1. String fileName = pfad.substring(pfad.lastIndexOf(System.getProperty("file.separator")) + 1, pfad.lastIndexOf("."));