Hi,
when the lot is created, the stock is moved to QA.
So, you have to clear the stock first then only can cancel the inspection lot.
First, you can either do force completion of the lot, or UD for the lot. It will ask you what to do with QA stock. Once that's moved to Unrestricted, you can go to QA12 and cancel the lot.
Thanks
Prem