If you like, you could use the tutorial as a workaround for now to be able to backup and restore your pinned taskbar items as needed before and after disconnecting and connecting the drive.
I have tried your backup-restore method, but unfortunately, when I restore the TaskBar, I see "broken shortcuts" restored and they disappear right away. Even though I turned off System Maintenance Troubleshooter and set "NoResolveTrack" option to "1" in the registry. Something is missing to make this work, but I can't figure what it is.
I've tried restoring TaskBar shortcuts when "broken shortcuts" are still there and they don't disappear after restoration process and even computer restart. I have checked System Maintenance Troubleshooter and "NoResolveTrack" after LibreOffice installation and both unchanged.
My Computer
At a glance
Windows 7 Professional 64-bitIntel Core i5-4670 LGA11508GBGeForce GTX 1060 GIGABYTE GV-N1060G1 GAMING-6GD
Computer type
PC/Desktop
Computer Manufacturer/Model Number
Custom
OS
Windows 7 Professional 64-bit
CPU
Intel Core i5-4670 LGA1150
Memory
8GB
Graphics Card(s)
GeForce GTX 1060 GIGABYTE GV-N1060G1 GAMING-6GD
PSU
Enermax Platimax EPM600 AWT 600W 80 Plus Platinum
Other Info
For history:
GPU: Asus GeForce GTS450 ENGTS450/DI/1GD5