add controls dynamically to a report

ashiashi Member Posts: 14
edited 2007-08-22 in Dynamics AX
Hi

How can we add controls dynamically to a report. Any help would be appriciated.
Thanks in advance


Regards,
Ashi

Comments

  • navaxnavax Member Posts: 16
    hi.
    this may helpful for u.....
    place this code in form init() in a new form
    public void init()
    {
        FormFunctionButtonControl   formFunctionButtonControl;
        ;
    
        formFunctionButtonControl = this.form().addControl(FormControlType::MenuFunctionButton, "Report");
        formFunctionButtonControl.menuItemType(MenuItemType::Output);
        formFunctionButtonControl.menuItemName(MenuItemoutputStr(Cust));
    
        super();
    }
    

    sunil....
  • ashiashi Member Posts: 14
    Thanks for ur reply.
    But i have already done it in the report.

    ReportTextControl _text;
    ;

    while(counter<i)
    {
    _text = element.design().sectionName('ProgrammableSection').addTextControl(months[counter]);
    }
Sign In or Register to comment.