to import tapes into the first empty slot of a tape library.
With the advent of BE 2012 and the introduction of BEMCLI, the earlier script which is based on BEMCMD cannot be used in BE 2012. Since BEMCLI has a richer set of cmdlets, this script also clears the media intervention alert asking you to put a tape into the mail/io slot. Previously, this clearance is not possible and it resulted in a 20 minutes wait for the alert to expire which eats into the backup window.
This script would not have been possible with the many contributions from Martin Hess who also tested it.
To use this script, make sure that you have changed your Powershell execution policy so that you can run scripts. See my article below on how to do so