至高吴上(Alfa.wu)

一个人,一生,能坚持做好一件事情是多么的牛XX啊!!!

  博客园  :: 首页  :: 新随笔  :: 联系 :: 订阅 订阅  :: 管理

2012年6月28日

摘要: c1flexgrid 通过 HitTestInfo 根据坐标 取得所在行 1 private void c1FlexGrid1_Click(object sender, EventArgs e) 2 { 3 MouseEventArgs mouseEvent = e as MouseEventArgs; 4 if (mouseEvent.Button == MouseButtons.Left) 5 { 6 if (c1FlexGrid1.Rows != nul... 阅读全文
posted @ 2012-06-28 19:46 Alfa 阅读(580) 评论(0) 推荐(0) 编辑

摘要: c1flexgrid 导出 Excel 非常方便就是一句话:第一个参数: 导出的目标文件路径,没有会创建.存在会覆盖.第二个能数.是导出的数据类型, FileFormatEnum.Excel : 导出Excel 类型,并且 Excel sheet 的名称为 sheet1,并且会把 c1flexgrid中的样式也一起导出. FileFormatEnum.TextComma: 导出为用 逗号","分格的数据格式FileFormatEnum.TextCustom 好像和 FileFormatEnum.TextTab 两项导出的差不多,目前我只发现,sheet名称不一样.前者导出的 阅读全文
posted @ 2012-06-28 14:54 Alfa 阅读(2566) 评论(0) 推荐(1) 编辑

摘要: 行号是这样设置的:首先要把 c1flexgrid 的 DrawMode 设置为: OwnerDraw 默认为: Normal然后就可以触发: c1FlexGrid1_OwnerDrawCell 事件了. 否则是不会触发的 private void c1FlexGrid1_OwnerDrawCell(object sender, OwnerDrawCellEventArgs e) { if (e.Row >= c1FlexGrid1.Rows.Fixed) { // 添加行号 c1FlexGrid1.Rows[e.Row][1] = e.Row - c1FlexGrid1.Rows.F.. 阅读全文
posted @ 2012-06-28 11:18 Alfa 阅读(2456) 评论(0) 推荐(0) 编辑