Modifying an existing AX 2009 Report......No zero amounts allowed in the report

Hello

I am modifying an RFQ Quotation Summary Report on AX 2009. The fields that I’m editing are “Value, Successful bid amount and the Order Number”. the scenario is ; if the field Value = 0, it must not appear (the field must be blank), “if the Value = 0, the Successful bid amount must not appear” and if the Successful bid amount = 0, the Order Number must not appear" Meaning any field with a 0 must not appear. All in all, there must be no fields with an amount of 0.

Please help.

Thank you.

Sponono

Hi,

You have 2 solutions:

-managing the display with the showZero Property from your field, if you set it on no, if your field has a zero value, it won’t be displayed, I mean the zero value, not your field

-Code on executeSection() method:you can manage the display of your whole field, if zero, it won’t be displayed, including the header

if (blblablayourConditions)

yourField.visible(false) or true;

(don’t forget to set the autodeclaration property on yes)

regards,

Thomas

Hi Thomas

On the first solution, this is the error I’m getting when I’m running the report: “Error executing code: ReportRun (data source) has no valid runable code in method ‘new’.
(C)\Classes\ReportRun\new
(C)\Classes\SysReportRun\new - line 9
(C)\Classes\ClassFactory\ReportRunClass - line 24”

For the second solution. I’m supposed to display the field blank if it’s value is zero. The header and everything must appear besides what’s inside of it, if it’s zero.

Thank you

Sinoyolo

Hi,

The error message is clear, there’s a problem in the new() method, changing the showZero property can’t be the cause of the problem, it’s the same as changing font size or bold.

I can’t find the RFQ Quotation Summary Report, is this custom made? can you show me the new() method code?

regards,

Thomas