How to access Args inside dialog() in a runbasebatch class?

Main method:

server static void main(Args args)
{
    VCInstrumentCreateForm   VCInstrumentCreateForm = VCInstrumentCreateForm::construct();

    if (!args || !args.record())
    {
        throw error(strFmt("@SYS29104", classStr(VCInstrumentCreateForm)));
    }

   
    if (VCInstrumentCreateForm.prompt())
        VCInstrumentCreateForm.run();

}

Dialog method

- I can get the caption through ARGS inside MAIN, however cannot access it through dialog method

public Object dialog()
{
    VCInstrumentCreateForm VCInstrumentCreateForm;
    DialogRunbase   dialog= Dialog::newFormnameRunbase(formstr(VCInstrumentCreateForm),this);

    dialog = this.dialogInternal(dialog);

    //PROBLEM HERE
    //dialog.caption("...caption will be coming from an args param...");
    
    dlgBillingScheduleGrp = dialog.addGroup("Billing Schedule date:");
    dlgStartDate = dialog.addField(extendedTypeStr(TransDate), "Start date:");
    dlgStartDate.value(startDate);
    dlgEndDate = dialog.addField(extendedTypeStr(TransDate), "End date");
    dlgEndDate.value(endDate);

Parents Reply Children
No Data
Related
Recommended