|
Hi,
I have a web application(made in ASP.NET ) which opens excel document in a frame by using Response.Redirect(@"/forum/some_path/Excel_2.xls", true);
.
To reproduce the error we need to open an excel(say Excel1.xls ) document using MS excel application. Then if i open an excel document(say Excel2.xls) using
my web application. The excel file is opening correctly in the frame but my problem is once the document is open in the frame(and also the frame size is change by user, without which the error does not occur!! )
It prevents use of Excel outside the application i.e Excel1.xls from operating correctly. It seems to be lock. No changes not even 'save' button works.
Here is a little demo, so that you all can recreate the bug easily.
This is home.aspx
..
<frameset name="fr_main" id="fr_main" rows="*,50%" frameborder="1">
<frame name="fTop" id="fTop" src="/forum/FrameTop.html" frameborder="1" >
<frame name="fBottom" id="fBottom" frameborder="1" >
</frameset>
..
In FrameTop.aspx
..
<body>
<form id="form1" runat="server">
<asp:HyperLink ID="LinkButton1" runat="server">HyperLink1</asp:HyperLink>
<asp:HyperLink ID="LinkButton2" runat="server">HyperLink2</asp:HyperLink>
</form>
</body>
.
In FrameTop.aspx.cs page
protected void Page_Load(object sender, EventArgs e)
{
LinkButton1.NavigateUrl = "/forum/FrameBottom_id_1.html" ;
LinkButton1.Target = "fBottom";
LinkButton2.NavigateUrl = "/forum/FrameBottom_id_2.html";
LinkButton2.Target = "fBottom";
}
In FrameBottom.aspx.cs
protected void Page_Load(object sender, EventArgs e)
{
string id=Request.QueryString["id"] ;
if (id == "1")
{
Response.Redirect(@"http://localhost/TestSite/TempFiles/Excel 1.xls", true);
}
else if (id == "2")
Response.Redirect(@"http://localhost/TestSite/TempFiles/fiber.bmp", true);
}
--------------------------------------
Before you run the application open another excel(not the same as the one in your web application) document by MS Excel application.
Thanks.
|
|
|
|
|
|
|
|
|
|