If you do a task on your computer more than once, you found some optimization potential. In my case, I had to add the year, month and day at I received the specific file in the file name way too often. This instructable will teach you, how to extend the windows context menues to run functions that improve your daily business!
The used script just adds the current timestamp as YYYYMMDD to the current file name. So "hello.txt" would be renamed to "20150724 - hello.txt".
Step 1: Write or Download the Script
In this example, we run some visual basic scripts in the background. Just click the following links and download the scripts to your computer, Make sure you save the files to a path that lasts forever:
Step 2: Hack Your Registry
To extend the windows context menus, you have to extend the windows registry. To do this, just press WIN+R and type "regedit". You may need administrator rights for this. If you see a window like shown in the screenshot, follow those steps:
- Navigate to this path (and create folders if they dont exist jet):
- HKEY_CLASSES_ROOT\*\shell\Add date as filename prefix
- Right click on the right side and hit "New" and then "Key"
- A new folder is created, just call this folder "command"
- Enter the folder
- On the right side, a entry called "(Default)" should already exist, double click on it
- Now just enter this as value (you may have to fix the path to your saved script):
cscript.exe A:\autoHotkey\add.modify.date.vbs "%1"
If you are done, do the same steps for HKEY_CLASSES_ROOT\*\shell\Add modify date as filename prefix\command and cscript.exe A:\autoHotkey\add.date.vbs "%1".
Step 3: Done
You may have to reboot your computer or just the explorer.exe. Your new functions now should automatically appear when you hit any files or at least file collections with your right mouse key!