Added functionality for the excel download.