The realm of the Paranormal

Ever thought of some wicked way to use 2xExplorer for extra functionality? Have you heard the stories about 1000 and one ways to open a beer bottle with all sorts of unsuitable artefacts ranging from one's teeth to one's socks? It's all about innovation and impressing one's friends down the pub. Below you'll find some such nice little numbers I came up with. Do you think you can do better? Can you mix it with the best of them? Tell us about it!

Adding more bookmarks

2xExplorer will just give you 6 direct bookmarks, and there's no way around this. However, you can use some cunning to get virtually unlimited bookmarks, managed by you. The way I do it is to create a folder called "C:\MyBookmarks" (the name is irrelevant) where I add links (shortcuts) to favorite folders. Then, I assign one of the 6 2x direct bookmarks (<Ctrl+0> is my choice) to "C:\MyBookmarks". I grant you that this is not as fast as a direct <Ctrl+xx> bookmark, since it involves an extra jump, but think of all the extra favourite folders you can manage! You can even organize relevant shortcuts in their own subfolders within your "C:\MyBookmarks".

NOTE: Don't forget that you can create links to folders simply by dragging them while holding <Ctrl+Shift>. In this way, a shortcut will be created where you drop the item instead of the default move/copy.

Assign a slot for scrap bookmarks

Another handy strategy that will help you move around faster in your filesystem is the notion of a scrap bookmark. This is a working bookmark that is meant to be changed all the time <Ctrl+1> is my preference. Say you are working in some folder and you have to nip down some other remote folder, both unbookmarked. What you can do is scrap-bookmark the working folder before leaving, so that you can immediately return from the remote folder when the time is nigh. Using your scrap slot guarantees that you won't overwrite any of your precious folder locations no need to struggle remembering which slot number is free any more!

The down side of course is that you "lose" yet another bookmark slot. It's two down, four to go...

Obtain a text list of all filenames

Remember the "Generate Batch" command <Ctrl+B>??  This is a powerful function capable of many more things than its name suggests. One that springs into mind is to generate a text file with the selected filenames (that could extend to a complete directory listing if need be). Using "$N" for the template you'll get all names in a convenient text buffer that can be saved and/or further edited. If you want the full path, that's easy too: just add one of the "$L" or "$R" tokens. You can then import this file into some decent document editor for further formatting and printing if you wish.

Mass-Renaming extensions

Let's use the "Generate Batch" command some more. This example actually also explains the use of it pretty well too. Let's say that you have a directory containing some 400 pictures with the extension ".jpeg" but your favorite paint program won't use them because it will only recognize ".jpg". Without 2xExplorer you'd have to rename every single file to use the ".jpg" extension, wasting about two hours. 2xExplorer allows you to select all the files (using Ctrl+A), select the "Generate Batch command, type in rename "$N" "$B.jpg" as the template, press "Create" and then "Execute" and watch all the files being renamed automatically. Cool as the morning dew, no? <g>

Simulate Norton Commander's "User Menu" behaviour

Do you remember the "User Menu" in NC? It provided a list of user-defined actions (i.e. programs) to perform on the current selection. The other day I was thinking of this handy feature, and how I could efficiently add it in 2x, when it dawned upon me that it was already there well sort of. You may have guessed that it's the jack-of-all-trades batch generator again coming to the rescue. Picture the following situation: you've done a <F9> comparison and a file was marked. Should you want to do a winDiff on it to see the details of the differences, here's how: Generate a "batch" using the template winDiff "$L\$N" "$R\$N" and execute the script, and presto, you've got your user command.

Since batch templates are persistent, you can have a collection of reusable commands like these, to suit your needs. Admitedly, the procedure is somewhat roundabout and not as clean as a simple UserMenu, but it works.

Synchronize directory trees

2xExplorer's synchronize <F9> command will only synchronize the two folders shown in the left and right panes, without going any deeper. However it is possible to synchronize complete subtrees using 2x's command executing potential combined with the good-old xcopy DOS command. Just browse your source folder in the left pane, the target in the right, jump to the address bar and type:

This will copy all the newer files and include those located in deeper levels, too. If you feel a bit rusty at first, you can include the /L option which will just show you what would be copied without actually doing anything:

Actually, this xcopy command is a real goldmine in terms of options, check out the documentation. I particularly like /T which can create just the directory structure devoid of files. It even removes the read-only attribute, need I say more? As usual, you only have to type this command once, and then it will be available for other folder pairs via the command history <Ctrl+F10> directive. Thanks to Gerrit Kiers for the tip.