This week's book giveaway is in the Other Languages forum.
We're giving away four copies of Functional Reactive Programming and have Stephen Blackheath and Anthony Jones on-line!
See this thread for details.
Win a copy of Functional Reactive Programming this week in the Other Languages 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: 21504
84
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