Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

file path to url

 
Sherif Shehab
Ranch Hand
Posts: 485
Android Eclipse IDE Oracle
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi i wanna change a normal file path to url format . for instance file path: c:\MyFolder\Myfile.txt i wanna change this path to URL so how i can do that ?
 
Campbell Ritchie
Sheriff
Posts: 48910
58
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
With the appropriate method in the java.io.File class.
 
Rob Spoor
Sheriff
Pie
Posts: 20526
54
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
And once you've found that one, notice it is deprecated and read what you should use instead. It's all in the API
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic