These changes might not make it into the main repository, but importDatabase() now accepts an already open file and exportTablesToExcel() now does not require the third  parameter and it now returns a string. The string exportTablesToExcel() returns can be immediately written to a file and opened as a .csv formatted spreadsheet. Obviously, you can do whatever you want with the string though, it is a string after all.