D365 Finance & Operations and Dynamics AX Forum

Expand all | Collapse all

Packing Slip reports with two designs

  • 1.  Packing Slip reports with two designs

    Posted May 28, 2020 10:41 PM

    Hi Experts,

    I have two report designs for packing slip which prints one after the other after packing slip is posted

    I want Note Type to display on Report design of Packing slip and Cert to display on CERT Report design

    Here is what i hvae done so far

    • Declared boolean isCert in SalesPackingSlipDP class decleration
    • In process report method

    if(objContract.parmDocumentTitle() == literalStr("@SYS11549"))

        {

            isCert = false;

        }

        else

        {

            isCert = True;

        }

    • In SetSalesPackingSlipDetailsTmp method

       if ((custFormletterDocument.DocuOnPackingSlip == DocuOnFormular::Line)

                 || (custFormletterDocument.DocuOnPackingSlip == DocuOnFormular::All))

                {

                    If(isCert)

                    {

                        docuRefSearch = DocuRefSearch::newTypeIdAndRestriction(custPackingSlipTrans,"CERT",DocuRestriction::External);

                        salesPackingSlipTmp.Notes                   = Docu::concatDocuRefNotes(docuRefSearch);

                    }

                    else

                   {

                        docuRefSearch = DocuRefSearch::newTypeIdAndRestriction(custPackingSlipTrans,custFormletterDocument.DocuTypePackingSlip,DocuRestriction::External);

                        salesPackingSlipTmp.Notes                   = Docu::concatDocuRefNotes(docuRefSearch);

                    }

                }

    The issue is output displays certification type notes in both reports and unable to switch between designs in code

    Debugged few times but was unable to get an idea where the designs are switching

    Kindly advice



    ------------------------------
    Shankar Iyer

    ------------------------------
    Academy - Online Interactive Learning from Experts


  • 2.  RE: Packing Slip reports with two designs

    Posted Jun 01, 2020 08:12 AM
    Hi Shankar,

    I assume this is AX2012. Please check SalesPackingSlipController\output
    I don't have AX2012 installed right now, only D365FO, but idea is the same.

    ------------------------------
    Volodymyr Skorobogatko
    ENAVATE
    Englewood CO
    ------------------------------

    Academy - Online Interactive Learning from Experts


If you've found this thread useful, dive deeper into User Group community content by role