Compare excel data tables

Hello. I am having some struggles and I will try to explain you why: I am doing a project where I need to scrap some data from a website to excel (just a column with codes like “F91243”), and inside this excel I have 2 sheets. In sheet 1 I have all the codes that I already analyse in my project, and in sheet 2 I have those codes that I scrapped that I need to analyze. So I need to compare this 2 sheets and I need to use an if, because IF the code in sheet 2 doesn’t exist in sheet 1, my program download some files, and after the download this code has to go to sheet 1 (and disappears from sheet 2), BUT IF the code in sheet 2 exists in sheet 1, the code has to be deleted and my program continues for the next code. Can someone help me?