我将Spread的一列定义为imagebutton,怎样触发这些imagebutton的单击事件??

解决方案 »

  1.   

    for (i = 0; i < 2; i++)
    {
    FpSpread2.Sheets[0].Cells[i, 2].CellType = new FarPoint.Web.Spread.ButtonCellType   ("MyCommand", FarPoint.Web.Spread.ButtonType.ImageButton, "../Images/searchbutton.bmp"); FpSpread2.Sheets[0].Cells[i, 5].CellType = new FarPoint.Web.Spread.ButtonCellType("MyCommand", FarPoint.Web.Spread.ButtonType.ImageButton, "../Images/searchbutton.bmp");
    }
    如上代码,我将Spread的第二列和第五列定义为ImageButton,现在想获取这些ImageButton的click
    事件,并在事件中写代码,就象在Button的click事件中写代码,该如何做???
      

  2.   

    顶一下,没用过Spread的话,其他二维表格怎么解决类似问题的?
      

  3.   

    添加代码
    ImageButton.Click += new System.EventHandler(事件处理函数名);