zoukankan      html  css  js  c++  java
  • Changing the language at runtime in X++

    We recently had a case where the customer wanted to change the language being used for a given AX user at runtime.  The customer had sorted out how to change the language

    displayed in forms and reports but the buttons on the navigation pane were not getting updated.  Here is a way to handle this scenario:

    In the setSetup method of the SysUserSetup form within the if clause add the following:

    /*
    ex.
    the report must be using chinese language running,then runned the report after, Dynamics AX must be reset current language
    remark by Jimmy September 03th 2010
    */
    public void init()
    {
        ;
        infolog.language("ZH-HANS");//first set up running to the report have to chinese languages
        this.printJobSettings().suppressScalingMessage(true);//removed the report scaling messages
        //this.printJobSettings().clientPrintJobSettings().suppressScalingMessage(true);
    super(); /* ledgerReport_CN = element.args().caller(); isFiscalYearClosed = ledgerReport_CN.isFiscalYearClosed(); ..............get some of parameters */ this.query().interactive(false);//current report never interactived } public boolean fetch() { UserInfo UserInfo; ; .....user Customize has been builded query run in the fect method select firstonly UserInfo where UserInfo.id == CuruserId(); if (infolog.language() != UserInfo.language) { infolog.language(UserInfo.language); infolog.navPane().loadStartupButtons();
       Infolog.navPane().refreshFavorites(infolog.navPane().selectedFavoriteGroup(),xInfo::currentWorkspaceNum()); } return true; }
  • 相关阅读:
    常用DOS命令
    uCGUI窗口重绘代码分析
    STM32的FSMC总线驱动ili9341,掉电重启无法正常显示的问题
    再次编译 arm toolchains
    GDB和GDB Server
    QT Creator 环境使用 remote debug 调试 arm 程序
    [转]一个简洁的 systemd 操作指南
    用 bottle.py 写了个简单的升级包上传
    批量 ping 测试脚本(IP 扫描)
    float 对整形的取余运算
  • 原文地址:https://www.cnblogs.com/Fandyx/p/1816684.html
Copyright © 2011-2022 走看看