web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

AX 2012 customized SalesPackingSlip report - Run new design based on condition

(0) ShareShare
ReportReport
Posted on by

I want to run a different design for this report based on a simple condition (a customized field in CustPackingSlipJour).

I figured out I could possibly put that condition in SalesPackingSlipController preRunModifyContract method but  when I call this.ParmReportName(ssrsReportStr(SalesPackingSlip, NewReport)); it says the operand for the method is not an element.  How can I get it to see my new design properly?

*This post is locked for comments

I have the same question (0)
  • Community Member Profile Picture
    on at

    Just bumping for this week.

  • Sohaib Cheema Profile Picture
    49,438 User Group Leader on at

    kindly go through this discussion

  • Community Member Profile Picture
    on at

    Thanks, That is an odd solution but one that did allow it to compile.  

    Is there a best practice / solution for placing this parmReportName to change which design to run based on data?  

  • Community Member Profile Picture
    on at

    I just want to point out there is no outputReport in the Packing slip class.  There is outputreports.  but even stating parmReportName there it continues to run Report vs NewReport.  I no longer get compilation errors though.  I have even overriden parmReportName and put the logic there to use NewReport but it always runs Report.

  • Sohaib Cheema Profile Picture
    49,438 User Group Leader on at

    have you debugged it?

    it is changing somewhere after you set value for parmReport

  • Community Member Profile Picture
    on at

    I have,  at no point does the reportname change back.

    In fact there is a line in main() where it says:

          controller.initArgs(_args, ssrsReportStr(SalesPackingSlip, Report));

    I changed Report to NewReport and debugged it through up until the report is displayed and it never changes yet Report is being displayed instead of NewReport

  • Sohaib Cheema Profile Picture
    49,438 User Group Leader on at

    I just noticed now that you are saying there is no output report method.

    well if its not there create/override it.

  • Community Member Profile Picture
    on at

    It's not there to override.  

  • Sohaib Cheema Profile Picture
    49,438 User Group Leader on at

    if its not there, override it. to override a method, it id needed to right click the class.

    see below screenshot, I can override outputReport method in same report. The following image, I have taken from standard system.

    overrideOutputReport.png

  • Community Member Profile Picture
    on at

    I just missed it before, I was able to override it but it still does use the new report design when I call this.ParmReportName(ssrsReportStr(SalesPackingSlip, NewReport));

    and to add to this, debugging it retains NewReport the entire time up until the report pops up.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Martin Dráb Profile Picture

Martin Dráb 4 Most Valuable Professional

#1
Priya_K Profile Picture

Priya_K 4

#3
MyDynamicsNAV Profile Picture

MyDynamicsNAV 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans