Community
    • 登入

    Replace Notepad.exe

    已排程 已置頂 已鎖定 已移動 Help wanted · · · – – – · · ·
    11 貼文 4 Posters 6.6k 瀏覽
    正在載入更多貼文
    • 從舊到新
    • 從新到舊
    • 最多點贊
    回覆
    • 在新貼文中回覆
    登入後回覆
    此主題已被刪除。只有擁有主題管理權限的使用者可以查看。
    • Matthew ReedM
      Matthew Reed
      最後由 編輯

      I have already run the reg-edit file to replace the default txt editor with notepad++ (replace-notepad-with-npp.reg), but some programs I use often have a direct link to notepad.exe in the windows directory. Plus, I like to type “notepad” on the DOS command line and from batch files.

      I followed some on-line directions to remove notepad.exe from windows, windows\system32 and windows\syswow64. Then I copied notepad++.exe to those locations and renamed it to notepad.exe.

      That does not work. It does not make sense, the file should work. If I run notepad++.exe in the \windows directory, it works, but gives me some errors about SciLexer.DLL missing.

      Is there something in the code that checks the name? Is there any way to do this?

      I have tried making a lnk file - no good.
      Making a batch file - the batch file works good, but this app I use looks for the exe.
      I tried using a batch to exe conversion program, I can’t get Kaspersky to stop deleting the file.
      I finally get Kaspersky to stop deleting it, I get the same result as when I rename notepad++.exe.

      I am just out of luck?

      -Matt

      1 條回覆 最後回覆 回覆 引用 1
      • Jim DaileyJ
        Jim Dailey
        最後由 編輯

        @Matthew-Reed

        Install notepad++ somewhere else on your hard drive (c:\notepad++ will do).

        Change your PATH environment variable: set PATH=c:\notepad++;%PATH%

        Rename Notepad++.exe to notepad.exe

        That should do it.

        1 條回覆 最後回覆 回覆 引用 0
        • Matthew ReedM
          Matthew Reed
          最後由 Matthew Reed 編輯

          Currently notepad++ is installed in C:\Program Files\notepad++ (W10, 64 bit)

          And I have updated the path to that location.

          It seems that renaming the file is what causes the problem.

          Thanks for the suggestion! :)

          To test this I copied notepad++.exe to notepad.exe and kept it in the c:\Program Files\notepad++ directory.

          It will not execute!

          -Matt

          1 條回覆 最後回覆 回覆 引用 0
          • Matthew ReedM
            Matthew Reed
            最後由 編輯

            ALso, I have been looking at the EXE file to see if perhaps I could change all the “notepad++” strings to just “notepad”.

            And, I found dozens and dozens of funny quotes!

            Like: Kids are like farts… you can only stand yours.

            How do you turn these on?

            -Matt

            Claudia FrankC 2 條回覆 最後回覆 回覆 引用 0
            • Claudia FrankC
              Claudia Frank @Matthew Reed
              最後由 編輯

              @Matthew-Reed

              How do you turn these on?

              type the word random, highlight it and press f1

              Cheers
              Claudia

              Scott SumnerS 1 條回覆 最後回覆 回覆 引用 1
              • Claudia FrankC
                Claudia Frank @Matthew Reed
                最後由 編輯

                @Matthew-Reed

                what about using a hard link instead?

                Cheers
                Claudia

                1 條回覆 最後回覆 回覆 引用 1
                • Matthew ReedM
                  Matthew Reed
                  最後由 編輯

                  Thanks Claudia!

                  Weirder and weirder… If I create a hard-link named “testit.exe” it works. If I make a hard-link named “notepad.exe” it does not.

                  This has to be a windows thing. Something in windows is borking it up.

                  -Matt

                  Claudia FrankC 1 條回覆 最後回覆 回覆 引用 1
                  • Claudia FrankC
                    Claudia Frank @Matthew Reed
                    最後由 編輯

                    @Matthew-Reed

                    So I assume that notepad.exe is on the list of “secure” applications.
                    Unfortunately I do not have any windows to play with it .
                    What I would do is to run sysinternals procmon to see what is really going on.
                    Maybe this gives a hint what needs to be done.

                    Cheers
                    Claudia

                    1 條回覆 最後回覆 回覆 引用 0
                    • Scott SumnerS
                      Scott Sumner @Claudia Frank
                      最後由 編輯

                      @Claudia-Frank

                      type the word random, highlight it and press f1

                      This is supposed to do something?..didn’t for me.

                      Claudia FrankC 1 條回覆 最後回覆 回覆 引用 0
                      • Claudia FrankC
                        Claudia Frank @Scott Sumner
                        最後由 Claudia Frank 編輯

                        @Scott-Sumner
                        Hi Scott,

                        yes, it opens a new doc and writes one of the easter eggs into.

                        You did type the word random, didn’t you?

                        Cheers
                        Claudia

                        Scott SumnerS 1 條回覆 最後回覆 回覆 引用 0
                        • Scott SumnerS
                          Scott Sumner @Claudia Frank
                          最後由 編輯

                          @Claudia-Frank

                          Ah, at some point I must have unmapped F1. Looking at a default install, F1 is tied to “About Notepad++”. Activating “About Notepad++” via the mouse (on the ‘?’ menu) (with random highlighted) invokes the Easter Egg functionality, so it appears it is tied to that function rather than only the keystroke.

                          1 條回覆 最後回覆 回覆 引用 1
                          • 第一個貼文
                            最後的貼文
                          The Community of users of the Notepad++ text editor.
                          Powered by NodeBB | Contributors