G
Guest
I am sending Excel reports to web clients. Excel opens in internet explorer
displaying multiple sheets. It is pretty simple to do and works well. To do
it, a client clicks a link to an ASPX page that first generates Excel.htm
files (query string contains parameters for the specific reports) then uses
Response.Write() to stream and Excel workbook file back to the client. The
Workbook file, internally contains links to the Excel.htm files that were
just created.
The Excel workbook file that is sent back to the client looks similar to this:
<html xmlns="urn:schemas-microsoft-comfficeffice"
xmlns:x="urn:schemas-microsoft-comffice:excel"
xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta name="Excel Workbook Frameset">
<meta http-equiv=Content-Type content="text/html; charset=windows-1252">
<meta name=ProgId content=Excel.Sheet>
<meta name=Generator content="Microsoft Excel 9">
<xml>
<x:ExcelWorkbook>
<x:ExcelWorksheets>
<x:ExcelWorksheet>
<x:Name>Name of Sheet 1</x:Name>
<x:WorksheetSource HRef="sheet1.htm"/>
</x:ExcelWorksheet>
<x:ExcelWorksheet>
<x:Name>Work sheet 2</x:Name>
<x:WorksheetSource HRef="sheet2.htm"/>
</x:ExcelWorksheet>
</x:ExcelWorkbook>
</xml>
</head>
</html>
When IE receives the above HTML text (the workbook definition) excel
automatically looks for and retrieves sheet1.htm and sheet2.htm.
It all works great!
My problem is if there is more then one client hitting the server at the
same time. If this happens, then one of the clients might be trying to
generate the sheet.htm files when another one is retrieveing them. I would
have no problem using an Application.Lock if I could know when any one client
is done retrieving the files.
Can someone give me a solution?
I would appreciate it.
displaying multiple sheets. It is pretty simple to do and works well. To do
it, a client clicks a link to an ASPX page that first generates Excel.htm
files (query string contains parameters for the specific reports) then uses
Response.Write() to stream and Excel workbook file back to the client. The
Workbook file, internally contains links to the Excel.htm files that were
just created.
The Excel workbook file that is sent back to the client looks similar to this:
<html xmlns="urn:schemas-microsoft-comfficeffice"
xmlns:x="urn:schemas-microsoft-comffice:excel"
xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta name="Excel Workbook Frameset">
<meta http-equiv=Content-Type content="text/html; charset=windows-1252">
<meta name=ProgId content=Excel.Sheet>
<meta name=Generator content="Microsoft Excel 9">
<xml>
<x:ExcelWorkbook>
<x:ExcelWorksheets>
<x:ExcelWorksheet>
<x:Name>Name of Sheet 1</x:Name>
<x:WorksheetSource HRef="sheet1.htm"/>
</x:ExcelWorksheet>
<x:ExcelWorksheet>
<x:Name>Work sheet 2</x:Name>
<x:WorksheetSource HRef="sheet2.htm"/>
</x:ExcelWorksheet>
</x:ExcelWorkbook>
</xml>
</head>
</html>
When IE receives the above HTML text (the workbook definition) excel
automatically looks for and retrieves sheet1.htm and sheet2.htm.
It all works great!
My problem is if there is more then one client hitting the server at the
same time. If this happens, then one of the clients might be trying to
generate the sheet.htm files when another one is retrieveing them. I would
have no problem using an Application.Lock if I could know when any one client
is done retrieving the files.
Can someone give me a solution?
I would appreciate it.