Excel Workbook in IE

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:eek:="urn:schemas-microsoft-com:eek:ffice:eek:ffice"
xmlns:x="urn:schemas-microsoft-com:eek:ffice: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.
 
M

Marina

As soon as your page is done Response.Write 'ing, you should be able to
release the lock. After that it is traveling to the client's PC.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,763
Messages
2,569,562
Members
45,039
Latest member
CasimiraVa

Latest Threads

Top