找回密码
 立即注册

QQ登录

只需一步,快速开始

summonyyq

银牌会员

22

主题

69

帖子

3765

积分

银牌会员

积分
3765

活字格认证

summonyyq
银牌会员   /  发表于:2014-12-14 00:11  /   查看:3825  /  回复:1
如图,实现单元格中两种背景色。
2014121412054529.jpg (37.09 KB, 下载次数: 108)

1 个回复

倒序浏览
iceman
社区贡献组   /  发表于:2014-12-15 15:28:00
沙发
回复 1楼summonyyq的帖子

请尝试以下代码看能否满足您的需求:

  1.             FarPoint.Web.Spread.TextCellType t = new FarPoint.Web.Spread.TextCellType();
  2.             //t.CssClass = "CssStyle1";
  3.             t.ShowEditor = true;
  4.             FpSpread1.ActiveSheetView.Cells[0, 0].CellType = t;
  5.             FpSpread1.ActiveSheetView.Cells[0, 0].VerticalAlign = VerticalAlign.Middle;
  6.             FpSpread1.ActiveSheetView.Cells[0, 0].BackColor = Color.LightBlue;
  7.             FpSpread1.ActiveSheetView.SetText(0, 0, "I'm yellow");
  8.             FpSpread1.ActiveSheetView.Rows[0].Height = 200;

复制代码
回复 使用道具 举报
您需要登录后才可以回帖 登录 | 立即注册
返回顶部