找回密码
 立即注册

QQ登录

只需一步,快速开始

edsoft

论坛元老

40

主题

88

帖子

1万

积分

论坛元老

积分
11438

活字格认证

edsoft
论坛元老   /  发表于:2013-4-8 16:09  /   查看:5238  /  回复:3
怎么触发spread for asp.net 的buttoncelltype单击事件

3 个回复

倒序浏览
iceman
社区贡献组   /  发表于:2013-4-8 16:44:00
沙发
回复 1楼edsoft的帖子

edsoft 你好,
参考代码:
C#:

  1.         protected void Page_Load(object sender, EventArgs e)
  2.         {
  3.             if (IsPostBack)
  4.             {
  5.                 return;
  6.             }
  7.             FarPoint.Web.Spread.ButtonCellType btn = new FarPoint.Web.Spread.ButtonCellType();
  8.             btn.OnClientClick = "test()";
  9.             FpSpread1.ActiveSheetView.Cells[1, 1].CellType = btn;
  10.         }

  11.         protected void FpSpread1_ButtonCommand(object sender, FarPoint.Web.Spread.SpreadCommandEventArgs e)
  12.         {

  13.         }
复制代码


JS:

  1.     <script type="text/javascript">
  2.         function test() {
  3.             FpSpread1.CallBack("button");
  4.         }
  5.     </script>
复制代码
回复 使用道具 举报
edsoft
论坛元老   /  发表于:2013-4-9 14:35:00
板凳
回复 2楼iceman的帖子

谢谢 问题解决
回复 使用道具 举报
iceman
社区贡献组   /  发表于:2013-4-9 16:40:00
地板
回复 3楼edsoft的帖子

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