RSS

How to get rid of the report scaling message

20 Feb

When a report doesn’t fit on a page, depending on it’s properties Ax will resize the report. This is a powerful and very useful feature.
Now Ax will inform you that the report has been rescaled (Report is scaled xx percent to fit to page) and this message is generally not well received by users.

Users are annoyed by the message, they get it every time they run the report, they cannot do anything about it, they have to click to close the infolog, …

Ax has a builtin feature to suppress this scaling message. You can modify the init method of your report, and add something like this:

this.printJobSettings().suppressScalingMessage(true);

This is very effective and will do the job.
Only, this requires you to modify every report with these kind of messages.

A nicer way would be if we could switch it off in one place for all reports. Fortunately, this is possible as well.
Go to class SysReportRun, in the Run method, place following code before the call to super:

if(this.printJobSettings())
this.printJobSettings().suppressScalingMessage(true);

void run(boolean onlyReport = false)
{
// If this report is a webReport the run a webReport.
if (webSession() && runBaseReport)
{
runBaseReport.runWebReport();
}
else
{
// When running the report and onlyReport = true then run the report.
if (!onlyReport && runBaseReport)
{
if (runBaseReport.prompt())
{
runBaseReport.run();
}
// If the prompt returns false the do not run the report.
// The RunBaseReport.Run method calls the ReportRun.run method with the parm onlyReport = true.
return;
}
}

this.buildPrintGrandTotal();
this.buildPrintOnlyTotals();

// 30 december 2010
//scaling message suppressed by default
if(this.printJobSettings())
this.printJobSettings().suppressScalingMessage(true);
// 30 december 2010

super();
}

Now we don’t have to modify each and every report and our users are happy.

Note that you can still override the settings in your report. In some reports this is done by default, like SalesInvoice and SalesConfirm.

 
Leave a comment

Posted by on February 20, 2012 in Reports in AX 2009

 

Tags:

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

 
365 by Thijs

Blogging about Microsoft 365, Azure and Automation!

axhowto

Blog about ax with sample codes, tips and tricks.

GM Dynamics Blogs

Transform IT with Digital Trasformation and Social Innovation

Ms. Dynamic Millennial

Unboxing Microsoft Dynamics 365 for Finance and Operations

DynaD365Power

Exploring the new vision of the Power platform

Dynamics Vision 365

The FinOps pulse

Breaking Bong

I write when no one is watching

ErpCoder

Microsoft Dynamics 365 Business Management Solution Enthusiast

Dynamics 365 Finance

Dynamics 365 Finance & Much More.

Microsoft Dynamics AX

“ANYONE WHO STOPS LEARNING IS OLD, WHETHER AT TWENTY OR EIGHTY.” —HENRY FORD

Sumit Potbhare

Dynamics 365 for Commerce

iotsolution.se

This is your site about D365 (Finance and Supply Chain Management), IoT (Internet of Things) and HoloLens

Omni 365

Dynamics 365 Finance and Operations Blog

DIY D365

Power Platform Done Your Way

%d bloggers like this: