Hi @ jasa88,
Do you want to create a flow to insert a row in the excel, and if the excel is locked, the flow would wait for a few minutes and would insert the row to the excel again until the row is inserted in the excel.
I have made a test on my side, and try to use "Do until" to realize your needs, but I couldn't manage to realize your needs currently, I would try again in the later, if I could accomplish your needs in the flow, I would reply here.
Regards,
Alice Zhang