My bad and thanks for the response. Here is my situation i have a multiple workbook save on a folder. each workbook has 3 sheets in it. sheet order are main, summary and raw now there are instance that a workbook does not have summary sheet in it. i have a code that copies the 2nd sheet based on the order given but every time i run it, it copies the next sheet (raw) whenever summary sheet is missing