There are several ways, but you'd need to implement your solution using a server-side technology.
Simpliest way would be to create a CSV file (comma separated values) using the FileSystemObject.
A much more complex and far harder solution would be to run an instance of Excel itself and control it through the API. (Although a draw back of that would be that you would need to install Excel/Office onto the web server.)
There might be utilities available with API's for creating Excel files, but I've not heard of any.