浏览:208 2008-09-10 15:34 来自 迷路中的路人甲      :

输出的代码:

 

        //HttpContext.Current.Response.Clear();

        //HttpContext.Current.Response.AddHeader("Content-disposition", "attachment;filename=" + strfilename);

        //HttpContext.Current.Response.AddHeader("Content-Length",file.Length.ToString());

        //HttpContext.Current.Response.ContentType="application/octet-stream";

        //HttpContext.Current.Response.Filter.Close();

        //HttpContext.Current.Response.WriteFile(file.FullName);

        //HttpContext.Current.Response.End();

 

在弹出保存的对话框的时候,直接选择打开,就提示地址找不到的错误了。

文件应该是保存在IE的临时文件夹里面了。但是实际上是找不到content.IE5这个文件夹的。

但是奇怪的是,如果我开了一个word窗口,然后在点击输出doc文件的流就能打开。见鬼了,大家又遇到这个问题的吗?帮忙看看了。

 

 

收藏 楼主
  2个月前  绝版色狼      :

Response.BinaryWrite(filestreent);
1楼 回到顶楼 

注册用户登录后才能回复,登录注册
> 返回“ASP.NET”


其他话题

相关内容

相关链接
1 19187