zoukankan      html  css  js  c++  java
  • 获取当前数据源,初始化query对话框的过滤查询值(Report and Button)

    (一)Report

    --1)Form控件“Button”中的重载 clicked()  事件,传递Form中当前的值给Report

    --2)Report 弹出query对话框,重载 init()  和 fetch()方法初始化显示从Button传递过来的值

    public boolean fetch()
    {

        ESGIQCLine      _ESGIQCLine;
    ;


        while(_queryRun.next())
        {
            _ESGIQCLine  = _QueryRun.get(tablenum(ESGIQCLine));

            doing something.....................

        }
            
    return true;
    }

    ---------------------------------------------------------------------------------------------------------

    (二)Form -- Button

     

          获取query初始化对话框在Form中的Btton对象,由于元素对象没有该枚举类型,所以比较特殊,必须使用当前Form中的主表和次表(数据源)的TableNum来做元素对象值。

         button的clicked事件中可以如下,清除上次query运行操作成功的对象元素值,使之显示当前Form的相关值作为query的初始值!

    name    name ;

     

        name = 'T:'+num2str(tablenum(CSM_PackingListTable),1,0,1,0)+','

                         + num2str(tablenum(CSM_PackingListLine),1,0,1,0);
        delete_from SysLastValue
                     where SysLastValue.userId == Curuserid()

                     && SysLastValue.elementName == name;

  • 相关阅读:
    在 TB1 机器上编译并调试 TB 自带sample的方法
    C++编译错误 fatal error C1189: #error : The C++ Standard Library forbids macroizing keywords. Enable warning
    c++生成随机数
    Unity调用讯飞做语音听写(Android Studio版)
    TouchDesigner 编译FlexChop
    Behavior Designer知识点
    清除Unity缓存
    UnityEngine.UI.dll is in timestamps but is not known in assetdatabase
    Unity插件学习记录 -- SW Actions
    Unity3D 使用LineRenderer制作画板功能
  • 原文地址:https://www.cnblogs.com/Fandyx/p/2761550.html
Copyright © 2011-2022 走看看