modify to close and delete temp files
Merge remote-tracking branch 'xlsx/master'