Fix merge conflict
Fix order of writing sheet end and workbook header