Writing the same excel by different boys at the same time

I have an common (shared) excel for two different bots. If I run two bots at a time both have to connect to same excel and write into that excel simultaneously.
For suppose I've 2 bots for 2 tasks and they should update their task status in an output file which is common for both. If first bot is writing in the first row the second bot should write in 2nd row of the same excel and no bot should be failed.

Thanks in advance..
Hi Babjee,

I don't think that it's a good idea (or it can be done) to connect to one same file simultaneously. Instead of excel files, try to use database tables.