Category Archives: Windows 7

Win7 Library Tool

Windows 7 libraries are a really useful feature of Windows 7, however unfortunately they arrive in a slighly cut-down form out of the box. Microsoft decided against exposing some really useful capabilities to users, like adding network locations, pretty much the first thing I tried to do. You get this message:

Luckily, you can add network locations (and any other un-indexed locations), but it must be done programatically. MS supply a command line utility slutil.exe, candidate for the worst named executable in history. Pretty sure it stands for shell_library_util. Anyway, I decided to write a tool to make it easy to add network locations, and added a few other features as well:

  • Add network (UNC or mapped drive) and any other un-indexed folders to libraries.
  • Backup library configuration, such that a saved set of libraries can be instantly restored at any point (like after a re-install of the OS or for transfer between multiple computers).
  • Create a mirror of all libraries (using symbolic links) in [SystemDrive]:\libraries. This means you can reference all your files using a much shorter path, and also provides another entry-point to your files in many places in the Operating System (e.g. file open/save dialogs).
  • Change a library’s icon.

Hopefully it’s easy enough to use, so I don’t have to explain it 🙂

You can download it for free below. (Note: This will only run on >= Windows 7.)

Download Installer | Source Code

I must give credit to Josh Smith for his TreeView CodeProject article, upon which this solution is modelled.

The application uses the Microsoft API CodePack to manipulate libraries, which I encourage you to check out if you are writing software to integrate / take advantage of new features in Windows 7.

If you want to learn why and how libraries were introduced in Windows 7, including diving into the .library-ms file format, you can read this MSDN article.

Now featured on Tekzilla!

Network CHMs = Pain courtesy of IE

Despite being around since 1997, CHM files still remain a popular format for program help / documentation as well as ebooks. But opening them from a network drive was outlawed in 2005 after Microsoft released this security update. There was a registry hack workaround to enable it again, however this no longer works in Windows 7. The solution accepted on this thread involves two steps:

1. Add this registry key:


2. In Internet Explorer->Tools->Internet Options and add your network drive into the safe/trusted zones.

Just the thought of firing up IE gives me the security-shivers and I really don’t want to be messing about with ‘trusted zones’ – I don’t trust IE to do anything. I’m surprised the US government hasn’t yet advised its citizens against using IE, like Australia, France and Germany have.

Of course the whole reason this has anything to do with IE is because the built in HH.exe that is the default Html Help viewer on Windows uses IE as the web browser engine to display and navigate the HTML files inside the CHM. So we could avoid this whole problem if there was a CHM viewer that doesn’t use IE at all. Now to the motivation for this post:

Enter xCHM – this is an open-source project that predominantly provides support for viewing CHM files on non-windows platforms, however it has been ported to Windows, so you can kiss HH.exe goodbye, and open your CHMs from any network location without having to hack your registry or mess with IE zones!!

Download the Windows port of xCHM (look under xCHM for Win32).

FreeCommander + SuperCopier2

As fun as file systems are, you really don’t want to be spending longer than you have to when it comes to copying / moving / viewing files and navigating folders. I was saved years of grief fumbling about with Windows Explorer thanks to a mate’s advice to switch to TotalCommander back in 2003 (I still remember his look of horror when when I said ‘Total-what?’). When it comes to speed and efficiently, the keyboard is king, and TotalCommander and all the other *commander variants take advantage of that.

Last year I switched to FreeCommander, and am very happy. The main benefits for me are:

  • a more modern / nicer UI
  • ‘type to navigate’
  • plenty of customisation options
  • it’s free 🙂

Unfortunately there are some serious drawbacks:

  • The file-copy/move dialog is the Windows built-in one (which is down-right horrible)
  • The file-delete dialog is the Windows built-in one, and it’s modal to the application
  • The FTP client has a terrible time-out issue and is generally buggy

I’d like to solve all three of these, but I’m starting with the first.

Luckily, FreeCommander allows you to use an external copy/move program via an INI setting. I tried the free TeraCopy for a while, but when I discovered SuperCopier 2, it was perfect! It really is lightning quick at what it does, it doesn’t get in your way, and has all the options you need (pause, error handling etc.). The only problem is, as of v2.2, the copy interception code was re-written, and it could no longer be fully integrated with FreeCommander. To solve this problem, I have written a small executable in C++ called SC2Integration.exe that uses the API provided by SuperCopier 2 (available on their sourceforge site) to re-unite FreeCommander with this excellent file-copy replacement.

Simply drop SC2Integration.exe into your FreeCommander installation folder (or anywhere else you would like to store it) and add the following two lines under the [Form] section of your FreeCommander.ini file:

FileCopyPrg=%FcSrcPath%\SC2Integration.exe Copy "%ActivSelAsFile%" "%InactivDir%"
FileMovePrg=%FcSrcPath%\SC2Integration.exe Move "%ActivSelAsFile%" "%InactivDir%"

If you didn’t copy SC2Integration.exe into your FreeCommander installation directory, replace %FcSrcPath% with the full correct path (no quotes). On Windows 7 your FreeCommander.ini file is here by default:


Download the SC2Integration utility for free here.

UPDATE: If you get an error ‘Parsing arguments…’, make sure you add double quotes around %ActivSelAsFile% and %InactivDir% in your FreeCommander.ini.