找回密码
 注册
关于网站域名变更的通知
查看: 1406|回复: 3
打印 上一主题 下一主题

谁有整理过GRID的使用,求一个例子来参考

[复制链接]
  • TA的每日心情
    无聊
    2022-6-24 15:35
  • 签到天数: 2 天

    [LV.1]初来乍到

    跳转到指定楼层
    1#
    发表于 2012-11-7 09:22 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式

    EDA365欢迎您登录!

    您需要 登录 才可以下载或查看,没有帐号?注册

    x
    小弟最近在研究GRID的用法,找到了软件自带的一个例子,但它那些代码看起来有点费劲,求一个简单的例子用来参考,非常感谢!

    该用户从未签到

    2#
    发表于 2012-11-7 15:13 | 只看该作者
    那个代码已经是简单的了
    最多有点乱而已

    该用户从未签到

    3#
    发表于 2012-11-7 18:02 | 只看该作者
    不难看懂啊~
  • TA的每日心情
    无聊
    2022-6-24 15:35
  • 签到天数: 2 天

    [LV.1]初来乍到

    4#
     楼主| 发表于 2012-11-9 23:49 | 只看该作者
    本帖最后由 yneda 于 2012-11-10 10:16 编辑
    talient 发表于 2012-11-7 18:02
    不难看懂啊~


    恕小弟愚钝,有几个参数理解不了。
    还请您看看这代码错在那里,谢谢!

    refdes = axlDBGetDesign()->components->name
    refdes_array = listToVector(refdes )

    cols = 1 ;插入一列
    InsertCol(cols)

    rows = length(refdes ) ;插入N行并赋值
    InsertRows(rows)

    axlFormGridUpdate(grid_test_form "grid") ;刷新grid


    procedure( InsertCol(cols)
          let((p)
               p = make_formGridCol()
               p->fieldType = 'TEXT
               p->align = 'center
               p->colwidth = 2
               p->headText = "Refdes"
              axlFormGridInsertCol(grid_test_form "grid" p)
              t
              );end let
         ) ;end procedure

    procedure( InsertRows(rows)
            axlFormGridInsertRows(grid_test_form "grid" 1 rows)
            axlFormGridSetBatch(grid_test_form, "grid" 'set_cell, "Read")
        );end InsertRows(rows)

    procedure( set_cell(rows)
         let((cell i)
              cell = axlFormGridNewCell()
              cell->col = 1
              for(i 0 rows-1
                    cell->row = i + 1
                    cell->value = refdes_array[ i ]
                    axlFormGridBatch(cell)
                    );end for
               t
              );end let
    );end set_cell(rows)

    试了下不行,axlFormGridSetBatch() 这个函数不会用,求指点,谢谢!               

    您需要登录后才可以回帖 登录 | 注册

    本版积分规则

    关闭

    推荐内容上一条 /1 下一条

    EDA365公众号

    关于我们|手机版|EDA365电子论坛网 ( 粤ICP备18020198号-1 )

    GMT+8, 2025-6-16 03:06 , Processed in 0.078125 second(s), 23 queries , Gzip On.

    深圳市墨知创新科技有限公司

    地址:深圳市南山区科技生态园2栋A座805 电话:19926409050

    快速回复 返回顶部 返回列表