I have done this many times back in the old days ;-) Unfortunately that code cannot be found this quickly. I found this example to import:
<%
Set ExcelConn = Server.CreateObject("ADODB.Connection")
Set ExcelRS = Server.CreateObject("ADODB.Recordset")
ExcelConn.Provider = "Microsoft.Jet.OLEDB.4.0"
ExcelConn.Properties("Extended Properties").Value = "Excel 8.0"
ExcelConn.Open "C:\Sample\Sample.xls"
'get data from sheet
sSQL = "SELECT * FROM Sample$"
set ExcelRS = ExcelConn.Execute(sSQL)
'loop through each record in Excel and write it to access
'might be slow, but will work
Do until ExcelRS.EOF
myConn.Execute("INSERT INTO Sample_tbl(lname,fname,mi) VALUES ('" & ExcelRS("0") & "', '" & ExcelRS("1") & "','" & ExcelRS("2") & "')")
ExcelRS.MoveNext
Loop
ExcelRS.Close
set ExcelRS = NOTHING
objExcelConn.Close
set ExcelConn = NOTHING
objConnAccess.close
set objConnAccess = NOTHING
%>
And This tiny snippet for export, which pretty much comes down to adding the correct Content Type Heading:
<%@ Language=VBScript %>
<% Option Explicit
Response.ContentType = "application/vnd.ms-excel"
Response.AddHeader "Content-Disposition", "attachment; filename=sample.xls"
%>
<table>
<tr>
<td>Sample</td>
</tr>
</table>