Monday, 16 December 2013

AX Report 2009 displaying only on the last page

Hi, 
Normally developers need the term and condition or other stuff to be displayed only on the last page .To insert the footer only on the last page of Axapta report do the following stes.
1. Declare a boolean variable (pageFooter) in report class declaration method .
             public class ReportRun extends ObjectRun
            {
                 boolean pageFooter;
            }
2. Override the report fetch method with query 
          public boolean fetch()
          {
               boolean ret;
               ret = super();
               printPageFooter=false;
                while(queryrun.next())
                {

                }
               printPageFooter=true;
               return true;
          }

3. Override the executeSection method of footer 
      
          public void executeSection()
          {
                if(printPageFooter==true)

                super();
           }




No comments:

Post a Comment