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

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

Automatically exported report to file saved 3 times instead of 1

(0) ShareShare
ReportReport
Posted on by 6,480

Hello,

we have customized class that exports the quotation report into mhtml file.

To export file in desired destination, we have applied the path in document types.

After we run the report and customized class is executed we see that in the path applied in doc types 2 mhtml files are created with different names (e.g. mhtmlFile.mhtml and mhtmlFile_001.mhtml). 

But, also in the same path somehow new folder with random name is created and inside of this folder same mhtmlFile.mhtml is created.

As we debugged the code files are created in class SrsReportRunPrinter, method toFile().

Everything is standard code instead of our customized class, from where we call SalesQuotationEditLinesForm_Sales_Send.printJournal() once.

Below the call stack untill the toFile method.

[c] \Classes\SrsReportRunPrinter\toFile 25
[c] \Classes\SrsReportRunPrinter\printReport 15
[c] \Classes\SrsReportRunService\runReport 43
[c] \Classes\SrsReportRunImpl\runReport 7
[c] \Classes\SrsPrintMgmtController\runReport 65
[c] \Classes\PrintMgmtReportRun\execute 41
[c] \Classes\FormLetterReport\execute 10
[c] \Classes\SrsPrintMgmtFormLetterController\outputReport 17
[c] \Classes\TradeDocumentReportController\outputReport 18
[c] \Classes\SrsPrintMgmtFormLetterController\runOutputReports 26
[c] \Classes\SrsPrintMgmtController\outputReports 80
[c] \Classes\TradeDocumentReportController\output 6
[c] \Classes\SalesQuotationController\output 6
[c] \Classes\TradeDocumentReportController\runPrintMgmt 17
[c] \Classes\SrsPrintMgmtController\run 30
[c] \Classes\SysOperationController\startOperation 10
[c] \Classes\SrsReportRunController\startOperation 12
[c] \Classes\SrsPrintMgmtController\startOperation 14
[c] \Classes\SrsPrintMgmtFormLetterController\startOperation 14
[c] \Classes\SalesQuotationController\main 13
[c] \Classes\xMenuFunction\runClient
[s] \Classes\MenuFunction\runClient 18
[s] \Classes\MenuFunction\runSSRSMenuItem 8
[s] \Classes\MenuFunction\run 70
[s] \Data Dictionary\Tables\CustQuotationJour\Methods\printJournal 31
[s] \Classes\SalesQuotationEditLinesForm_Sales_Send\printJournal 8
[s] \Classes\customizedClass\printJournal 5
[s] \Classes\customizedClass\run 52
[s] \Classes\customizedClass\mainOnServer 77
[c] \Classes\customizedClass\main 29
[c] \Classes\FormFunctionButtonControl\Clicked

*This post is locked for comments

I have the same question (0)

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Meet the Microsoft Dynamics 365 Contact Center Champions

We are thrilled to have these Champions in our Community!

Congratulations to the March Top 10 Community Leaders

These are the community rock stars!

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Basit Profile Picture

Basit 1

#1
GL-01081504-0 Profile Picture

GL-01081504-0 1

#1
Roya Profile Picture

Roya 1

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans