找回密码
 立即注册

QQ登录

只需一步,快速开始

cngrain

中级会员

32

主题

118

帖子

656

积分

中级会员

积分
656

活字格认证

cngrain
中级会员   /  发表于:2014-6-26 17:07  /   查看:4443  /  回复:2
protected void btnExport_Click(object sender, EventArgs e)
        {
            FarPoint.Web.Spread.FpSpread ExportSpread = new FarPoint.Web.Spread.FpSpread();
            ExportSpread = fpSpreadScan;
            FarPoint.Web.Spread.SheetView pSheet = ExportSpread.Sheets[0];
            pSheet.ColumnFooterVisible = false;
            pSheet.RowHeaderVisible = false;
            if (ExportSpread.Sheets.Count <= 0)
            {
                ExportSpread.Sheets.Add(pSheet);
                ExportSpread.Sheets[0] = pSheet;
            }
            else
            {
                ExportSpread.Sheets[0] = pSheet;
            }


            for (int rowindex = 2; rowindex < ExportSpread.Sheets[0].RowCount - 1; rowindex++)
            {
                for (int col = 0; col < 13; col++)
                {
                    ExportSpread.ActiveSheetView.Cells[rowindex, col].Border = new Border(BorderStyle.Solid, Color.Black, 2);
                }
            }
            //ExportSpread.Sheets[0].Cells[3, 9].Border.BorderStyleBottom = BorderStyle.Solid;//单元格底部有边框
            //ExportSpread.Sheets[0].Cells[rowindex, colindex].Border.BorderStyleTop = BorderStyle.Solid;//上部有边框
            ExportSpread.Sheets[0].Cells[3, 9].Border.BorderStyleRight = BorderStyle.None;//右边无边框
            ExportSpread.Sheets[0].Cells[3, 10].Border.BorderStyleLeft = BorderStyle.None;//左侧无边框



            fpSpreadScan.SaveExcelToResponse(string.Format("{0}.xls", DateTime.Now.ToString("yyyyMMddHHmmssff")));
        }
这个是我的导出方法。有些用户的IE8  浏览器 兼容/非兼容模式下导出都是只有画出的表格边框 而没有里面的数据
中华粮网

2 个回复

倒序浏览
cngrain
中级会员   /  发表于:2014-6-27 11:09:00
沙发
同样的系统,部署在server 2003 sp2 上面  我的机器 IE8 火狐都 可以正常导出, 同事的IE11 调各种模式都不能正常导出。但火狐可以正常导出。
部署在server 2008 r2 SP1 64位上面。 WIN7 IE8均不能正常导出 火狐可以正常导出。
IE 版本有 8.0.6001.18702IS   8.0.7600.16385   8.0.7601.17514
中华粮网
回复 使用道具 举报
iceman
社区贡献组   /  发表于:2014-6-27 15:58:00
板凳
回复 2楼cngrain的帖子

你好,

感谢详细的问题反馈。

Spread for ASP.NET 6.0 不支持 IE11 ,如果需要解决可以升级到 7.0。
其他OS 和 浏览器信息,我正在尝试。

有结果反馈给你。
回复 使用道具 举报
您需要登录后才可以回帖 登录 | 立即注册
返回顶部