This spreadsheet will place a back bet at the current best back odds and when matched placed a lay bet for the same stake at the current best lay odds. You must select to log My Bets when linking to the spreadsheet for it to work correctly.
It uses the SUMIFS function to calculate the total matched back and lay stakes. When they are the same it means another back can be triggered as the previous trade is closed. It only checks up to row 100 on my bets so if the number of bets exceeds 99 it will not work correctly.
Download here