1

As you all know, when you make new folder, its name is New folder. If you add second folder, New folder (2). I want to change it with newnew and i have changed it successfully with registry changes(via instructions on winaero). In summary, i added a key called NamingTemplates on HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer and added string value called RenameNameTemplate and filled it with "newnew".

But also i want to change it newnew2, newnew3, instead of newnew (2), newnew (3). I.e without parentheses and spaces.

How can i do?

1 Answer 1

1

Windows Explorer cannot be customized for that. You need to use a third-party tool. I use here the free AutoHotkey.

The following script will map Ctrl+N to create a new folder inside the current folder:

newname=newnew         ; this is the folder's prefix string
^n::                   ; map ctrl-N
Z = 0
Loop
{
    Z++
    Path := GetActiveExplorerPath()
    CandidateName = %Path%\%newname%%Z%
    IfNotExist, %CandidateName%
    {
         FileCreateDir, %CandidateName%
         break
    }
}
return

GetActiveExplorerPath()
{
    explorerHwnd := WinActive("ahk_class CabinetWClass")
    if (explorerHwnd)
    {
        for window in ComObjCreate("Shell.Application").Windows
        {
            if (window.hwnd==explorerHwnd)
                return window.Document.Folder.Self.Path
        }
    }
}

After installing AutoHotKey, put the above text in a .ahk file and double-click it to test. You may stop the script by right-click on the green H icon in the traybar and choosing Exit. To have it run on login, place it in the Startup group at
C:\Users\USER-NAME\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup.

Useful AutoHotkey documentation:

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .