http://www.perlmonks.org?node_id=1056249


in reply to Re^6: Not able to create worksheets inside a subroutine
in thread Not able to create worksheets inside a subroutine

Try adding $workbook->close() as last statement.
poj