I do not recommend this approach.
Tape adhesive does not hold up long term, especially in situations where it's exposed to heat or oscillating temperature changes. Over time, that tape is likely to fail and the drive will fall loose from the sled at an angle, which will torque the drive connector on your backplane/main board and destroy the board, your drive, your data, and possibly other components in your system in the process.
If you're going to use a poor man's solution like this, try wrapping the drive tightly in a complete circle of tape (more than once) so the length of tape acts as a restraint (or safety net, if you will) against the drive falling. Better, but still not a great solution.
A great solution: Buy a new tray. They cost less than $20 and that's a tiny investment to guarantee the safety of your (very expensive) equipment and your data!