Bug: renaming doesn't work if new name is the same with different capitalization
-
If I try to rename
header.md
toHEADER.md
, I’m prompted if I want to overwrite the existingheader.md
.
I confirmed that, but it didn’t do anything. The file is still calledheader.md
in Notepad++ as well as in Explorer (the actual file system).Windows 8.1 (64bit), NP v6.9
-
Hello @CoDEmanX47
this comes from the windows open file dialog which seems to reuse
the original filename when the file already exists.
Afaik the only way npp could tweak this is to call MoveFileEx twice,
the first time with a temporary name and the second time with the new name.
So something likeMoveFileEx("old_name","temporary_name") MoveFileEx("temporary_name", "new_name")
Cheers
Claudia -
When rereading it I see that it isn’t really complete.
What I wanted to say isAfaik the only way npp could tweak this is to call MoveFileEx twice,
the first time with a temporary name and the second time with the new name,
and to ignore the open file dialog at all if it is just a renaming action.Cheers
Claudia -
Hi, CoDEmanX47 and Claudia,,
I’m just back on N++ forums, after a three-days ski course, at Chamonix, some family events and ski, again, yesterday, at La Rosière (FR) - La Thuile (I), with sun, blue sky :-) … and some falls :-((
Just for info : Seemingly, after a try, I was able, on my Win XP configuration, to change the N++'s readme.txt file, in one go, with the new name ReadMe.txt, after confirming the classical window about overwriting the existing file !
Immediately, the readme.txt tab, in N++, was renamed as ReadMe.txt, and, after updating my explorer window, the name of the file was displayed with this new capitalization !
Best Regards,
guy038
P. S. :
BTW, Claudia, it seems that your skills are increasing ! Indeed, from now on, you also act as a doctor ;-D
I’m referring to the post, below :
https://notepad-plus-plus.org/community/topic/11456/inserting-and-in-long-group-of-attributes/3
-
Hello guy038,
I’m so sorry for you, you have to skiing all the day, in the sun and blue sky - it must be terrible musn’t it? ;-D
Actually you are right, it works with XP but not in windows 7/10 x64. Seems MS changed the api.
BTW, Claudia, it seems that your skills are increasing ! Indeed, from now on, you also act as a doctor
:-D but I wouldn’t medicate myself - maybe mental disease ;-)Cheers
Claudia