Win a copy of Practical SVG this week in the HTML/CSS/JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

How can we found the fileseparator

 
Gaurav Chikara
Ranch Hand
Posts: 413
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If i want to concatenate a string with the system dependent path separator then which is the best way to find it
I tried using System.out.println(File.pathSeparator); on
Windows Platform then it gave ; as output it is quite surprising how can it give ; as path separator
any views
 
Amar, Nandigam
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Gaurav,
you should use File.separator rather than File.pathSeparator to find the platform specific separator.

amar.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!