AutoRun for other devices
In analogy to the AutoRun function for storage volumes, USBDLM can execute a command-line on arrival and removal of any device.
The one and only device specific criteria is the device ID.
You find the device ID in the Windows Device Manager. Right-click the device -> Properties. Select the "Details" tab. Here the "Device Instance ID" is already selected. Click on the ID and press "Ctrl+C" to copy the ID into the Windows Clipboard.
XP before SP2 show the tab "Details" when the environment variable DEVMGR_SHOW_DETAILS is set to 1. This REG file adds this variable:
It takes effect after the next logon.
Since V4.7.1 all criteria not related to a newly arrive drive are available here too. These are Files, User, computer name, running process, operating system and time.
Sample for starting the calculator on arrival of a certain USB device:
[OnDeviceArrival]
DeviceID1=USB\VID_090C&PID_1000\A740000000000097
open=calc
The same after removal:
[OnDeviceRemoval]
DeviceID1=USB\VID_090C&PID_1000\A740000000000097
open=calc
Hint: There is no [OnDeviceRemovalRequest].
The other parameters known from [OnArrival], as openstyle, system etc work here too.