The Original Gay Porn Community - Free Gay Movies and Photos, Gay Porn Site Reviews and Adult Gay Forums

  • Welcome To Just Us Boys - The World's Largest Gay Message Board Community

    In order to comply with recent US Supreme Court rulings regarding adult content, we will be making changes in the future to require that you log into your account to view adult content on the site.
    If you do not have an account, please register.
    REGISTER HERE - 100% FREE / We Will Never Sell Your Info

    PLEASE READ: To register, turn off your VPN (iPhone users- disable iCloud); you can re-enable the VPN after registration. You must maintain an active email address on your account: disposable email addresses cannot be used to register.

Can't Rename A File .. WTF?

72-Jay

Daydreamer
Joined
Oct 24, 2011
Posts
7,527
Reaction score
549
Points
113
Location
(somewhere in colorado)
So I have this soundfile that I want to rename, but when I try to do so windows gives an error...

Cannot rename file: The filename you specified is invalid or too long. Specify a different filename.
Doesn't matter what I try (even a single character) for the name, it still gives the same error.
If I try moving or copying it i also get a very similar error.
Anyone ever have that happen?

The orig name certainly isn't invalid, but there is a chance it could be too long (I thought the limit was 255 characters? .. is it actually 127? (It'd be 1 over if that's the limit))
 
That 255 characters includes the entire file path so a file named music.mp3 in your music directory actual full name might be something like c:\users\stardreamer\my music\music album\music.mp3

We get this error at work when folks like to put whole titles of a document in the filename not realizing this and get the same error.
 
Didn't realize both the path & extension (.mp3 in this case) counted too

Just weird that the crazy thing wouldn't even let me rename it to something shorter LOL...
Only way I was able to fix it was to go to DOS and rename from there :)

I did some playing around too...looks like the limit is 250 characters if its in the root directory.

(ofcourse original said file was in a temporary directory I made...then multiple subdirectories down ... so limit there was 127ch, but the file was actually 5 over - 132ch when counting the extension too)
 
The short file names that Windows supports really irks me. I think NTFS can actually support a very long file name, but the Windows APIs have a hard limit near 255. There are a few ways around it, but taking advantage of them can break other things.
 
Only way I was able to fix it was to go to DOS and rename from there :)

Yes, that works. One trick too is that since the path from root through all folders to the file count, you can start renaming any of the folders to that file something shorter and the rename will work on the folders from within Windows. When you shorten that stuff up, the file should then become instantly available for renaming, deleting, etc.

For instance (just making this up here):

c:\Documents and Settings\Whomever\My Files\My Pictures (Converted from Old Computer External Drive)\Trip Photos\2013 Trip to Greece and Venice\Day 1 - Boat and Dock Stuff Color Corrected\Boat Excursion\Long Crazy Filename Here (Down-resed for slideshow version).jpg

you could pick any folder (best to stick to the ones you create and not Windows standard ones though) and rename it shorter, such as:

c:\Documents and Settings\Whomever\My Files\My Pictures (Converted from Old Computer External Drive)\Trip Photos\13GreVen\Day 1 - Boat and Dock Stuff Color Corrected\Boat\Long Crazy Filename Here (Down-resed for slideshow version).jpg


Sometimes if people have crazy-long paths for some legitimate need, I might recommend they can map the folder to a virtual drive letter - give a whole long path the drive "Z:" on your system for instance. Or, if it's an option, partition a data hard drive into different drive letters and use one drive letter for documents, another for your photos, another for your organization or spreadsheets.

Also, if it's not a filename-length issue, or if an antivirus or something stubborn in Windows is choking on the long length, Unlocker might help at unlocking the process that's holding the file.
 
Something I have encountered before which nobody has mentioned yet but there is a possibility that the file is "permission" locked. I deal with this problem about once a week when an associate tries to rename a file before submitting it and cannot. I have also inadvertently done this a few times when transferring files between my desktop and laptop.

Usually the originator or admin has full-access permission to rename a file. Of course when this happens, you are usually prompted when renaming a file anyway.
 
I didn't think to try renaming any of the folders/sub's (I've since done deleted some extra sub's & shortened its foldername..because I didn't want/need all the extra crap that was originally there)
<I also never use any of those windows default things like 'my documents' LOL>
----

I have ran into things on computers where a file or folder is permission locked (my solution to that was to take ownership of it) ..
The system where this file is, that wouldn't be an issue though.
 
Back
Top