Community

    • Login
    • Search
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search

    Bug: renaming doesn't work if new name is the same with different capitalization

    General Discussion
    3
    5
    2867
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • CoDEmanX47
      CoDEmanX47 last edited by

      If I try to rename header.md to HEADER.md, I’m prompted if I want to overwrite the existing header.md.
      I confirmed that, but it didn’t do anything. The file is still called header.md in Notepad++ as well as in Explorer (the actual file system).

      Windows 8.1 (64bit), NP v6.9

      Claudia Frank 1 Reply Last reply Reply Quote 0
      • Claudia Frank
        Claudia Frank @CoDEmanX47 last edited by

        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 like

        MoveFileEx("old_name","temporary_name")
        MoveFileEx("temporary_name", "new_name")
        

        Cheers
        Claudia

        1 Reply Last reply Reply Quote 0
        • Claudia Frank
          Claudia Frank last edited by

          When rereading it I see that it isn’t really complete.
          What I wanted to say is

          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,

          and to ignore the open file dialog at all if it is just a renaming action.

          Cheers
          Claudia

          1 Reply Last reply Reply Quote 0
          • guy038
            guy038 last edited by

            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

            1 Reply Last reply Reply Quote 0
            • Claudia Frank
              Claudia Frank last edited by

              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

              1 Reply Last reply Reply Quote 0
              • First post
                Last post
              Copyright © 2014 NodeBB Forums | Contributors