Win a copy of Learn Spring Security (video course) this week in the Spring forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Rename File is fail

 
Randika Isuru
Ranch Hand
Posts: 38
Java Linux Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,
please any one can tell me why this code give me a output false
are there any thing wrong in my code i don't think so. please correct me



This code give me output : File renamed? false

Thanks...
 
Henry Wong
author
Marshal
Pie
Posts: 20880
75
C++ Chrome Eclipse IDE Firefox Browser Java jQuery Linux VI Editor Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Randika Isuru wrote:
please any one can tell me why this code give me a output false
are there any thing wrong in my code i don't think so. please correct me



This code give me output : File renamed? false




Try it from the command line. Create two files (anyway you like). And then try to rename one of the files to be the same as the name of the other file. You will notice that the operating system doesn't like that.

Henry
 
Randika Isuru
Ranch Hand
Posts: 38
Java Linux Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ohhhhhhhhh no!!!
i forget that
Thank you very much "Henry Wong"
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic