The Messenger of Allah (ﷺ)as saying: When the iqamah is pronounced for prayer, no prayer is valid except the obligatory prayer.
Sunan Abi Dawud Book 5, Hadith 17