Sunday, June 18, 2023

how to open TransTaxInformation form by Custom Button.

TaxInformation:-

The Control called "Tax Information" is present in the PurchTable form. My requirement is to add the same control in purcheditlines and populate data the same as standard control data.

[ExtensionOf(formcontrolstr(PurchEditLines,TaxInformation))]

internal final class Dax_PurchEditLInes_TaxInformation_Extension

{

   public void clicked()

   {

       Args            args;

       FormRun         formRun,formrunloca,formrunpurchtable;

       PurchLine       purchline;

       FormControl     formcontrol ;

       PurchParmLine   purchparmline;

 

       next clicked();

 

       formcontrol = any2Object(this);

       formrunloca = formcontrol.formRun();

 

       purchparmline = formrunloca.dataSource().cursor();

 

       select * from purchline

           where purchline.PurchId == purchparmline.OrigPurchId

           && purchline.ItemId     == purchparmline.ItemId;

 

       args = new Args();

       args.name(formStr(PurchTable));

       formrunpurchtable = new FormRun(args);

       formrunpurchtable.init();

       formrunpurchtable.run();

       formrunpurchtable.close();

       args.name(formStr(TransTaxInformation));

       args.record(purchline);

       args.caller(formrunpurchtable);

      

       formRun = New FormRun(args);

       formRun.init();

       formRun.run();

       formRun.wait();

       

    }

 

   }

  





No comments:

Post a Comment

My Requirement is Delete option in Vendor Master for all roles except System Administrator

   [FormControlEventHandler(formControlStr(VendParameters, VendParameters_YNV_VendorMasterDeletionOption), FormControlEventType::Modified)] ...