you cannot convert it to item:
if its a rawcode, its because as they are two totally different things...
if its a handleId, its because there is only a function that obtains HandleId, but there is no function for the reverse
but you could loop through all slots, and check if the item in that slot is equal to the value of the integer variable... if yes, remove the item...