Three times it is said: did we not [verse 22]…in Your Name? He says “I never knew you.” Never. Then in verse 23 He says: Depart from Me, you that work iniquity.” Who is the father of iniquity? Answer: Satan. Jesus said they work iniquity. So whose name are they doing the things in, because Jesus does not know them, if they are working iniquity, as stated in verse 22? Only two Gods have a Kingdom: (i) Jesus the King of righteousness; and (ii) Satan, the king (prince) of darkness. So the answer is they were doing these things in the name of Satan—the father of iniquity.
See: Matthew 13–the words of Jesus to His disciples about the Kingdom of Heaven
21 Not every one that saith unto me, Lord, Lord, shall enter into the kingdom of heaven; but he that doeth the will of my Father which is in heaven.
22 Many will say to me in that day, Lord, Lord, have we not prophesied in thy name? and in thy name have cast out devils? and in thy name done many wonderful works?
23 And then will I profess unto them, I never knew you: depart from me, ye that work iniquity.