From: Periyasamy Ramachandiran Date: 2012-06-15T21:09:18+09:00 Subject: Re: File.delete()-Permission denied error in windows Damián M. González wrote in post #1064721: > Mmmm, not prety sure, but when you are moving a file or dir with > FileUtils, you are deleting it too from the previous location, so the > work is done simply calling the mv() FileUtils method, you don't have to > 'delete' it... Damian, Thanks for your reply. You are right!. First I tired to move the file from one directory to another directory. Then, I got the permission denied error and the file can't be moved. So, I tried in another solution instead of mv() (moving file), I just tried to copy the file to the destination directory. Here, the file is copied to the destination directory. But I am unable to delete the source file when I use "File.delete(file)". Because I am getting the same "Permission denied error". Please let me know your comments. Thanks, Periyasamy -- Posted via http://www.ruby-forum.com/.