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 :
Dynamics 365 Community / Forums / Finance forum / Error: Something went ...
Finance forum

Error: Something went wrong while generating the report. Please try again.

(0) ShareShare
ReportReport
Posted on by

Hi Community,
I have created a new Project where I want to customize my the standard freetextinvoice.

What I have done so far is simple and I hope the best way to do so, if not please give recommendations.
I created my project and copied standard classes into my project and they got the names at first
"FreeTextInvoiceControllerCopy", "FreeTextInvoiceDPCopy", "FreeTextInvoiceContractCopy", and created a Handler class "FreeTextInvoiceHander":

class FreeTextInvoiceHandler
{
[SubscribesTo(classstr(PrintMgmtDocType), delegatestr(PrintMgmtDocType, getDefaultReportFormatDelegate))]
public static void getDefaultReportFormatDelegate(PrintMgmtDocumentType _docType, EventHandlerResult _result)
{
switch (_docType)
{
case PrintMgmtDocumentType::SalesFreeTextInvoice:
_result.result(ssrsReportStr(FreeTextInvoiceCopy1, Report));
break;
}
}

}

I also extended FreeTextInvoice output MenuItem and changed the Object Property to "FreeTextInvoiceControllerCopy".

In Accounts Receivable/ Forms/ Form setup/ Print management/ FreeTextInvoice/ Original/ I changed the report Format to "FreeTextInvoiceCopy1.Report"

I believe that I might have to make some changes in the main method of my ControllerClass but I am not quite sure what changes, since I copied the standard it must actually work the same way.

When I select a record and try to open the report it won't open. 

  • Verified answer
    Sukrut Parab Profile Picture
    71,741 Moderator on at

    Look at event viewer and check if you see any error over there . Did you try to debug to see where its breaking ?  

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

November Spotlight Star - Khushbu Rajvi

Congratulations to a top community star!

Forum Structure Changes Coming on 11/8!

In our never-ending quest to help the Dynamics 365 Community members get answers faster …

Dynamics 365 Community Platform update – Oct 28

Welcome to the next edition of the Community Platform Update. This is a status …

Leaderboard > Finance

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans