Skip to main content

Notifications

Announcements

No record found.

Finance | Project Operations, Human Resources, ...
Unanswered

vendor payment advice report not printing/running after update (10.0.31)

Posted on by 1,534

Hi Expert

I am facing an issue after updating the D365 FO from old to (10.0.31), I have customized controller class through which we are printing our custom report design, but after update the system throw exception like, before update there was a class BankPaymAdviceVendController which later on updated to BankPaymAdviceVendControllerV2 in(10.0.31)

following are our customized class : 

  • BankPaymAdviceReportGeneratorVendExt 
  • BankPaymAdviceReportGeneratorExt
  • BankPaymAdviceReportGeneratorVendPostedExt

An error occurred when running report BankPaymAdviceVendV2.Report. Message: Unable to cast object of type 'Dynamics.AX.Application.BankPaymAdviceReportGeneratorVendExt' to type 'Dynamics.AX.Application.BankPaymAdviceReportGenerator'..
exceptionType System.InvalidCastException
stackTrace System.InvalidCastException: Unable to cast object of type 'Dynamics.AX.Application.BankPaymAdviceReportGeneratorVendExt' to type 'Dynamics.AX.Application.BankPaymAdviceReportGenerator'. at Dynamics.AX.Application.BankPaymAdviceReportGenerator.`newForJournal(String _ledgerJournalId) at Dynamics.AX.Application.BankPaymAdviceReportGenerator.newForJournal(String _ledgerJournalId) at Dynamics.AX.Application.BankPaymAdviceVendControllerV2.printLine(LedgerJournalTrans _ledgerJournalTrans, BankPaymAdviceContract _contract, SrsPrintDestinationSettings _printSettings, NoYes _shouldDefaultFromPrintMgmt) at Dynamics.AX.Application.BankPaymAdviceVendControllerV2.printContractQuery() at Dynamics.AX.Application.BankPaymAdviceVendControllerV2.`runPrintMgmt() at Dynamics.AX.Application.BankPaymAdviceVendControllerV2.runPrintMgmt() at Dynamics.AX.Application.SrsPrintMgmtController.run()

Appreciate your expert suggestions. 

  • GirishS Profile Picture
    GirishS 27,832 Super User 2024 Season 1 on at
    RE: vendor payment advice report not printing/running after update (10.0.31)

    Hi Munsif,

    I think this is due to the customization you have done.

    Code is trying to get object of type BankPaymAdviceReportGenerator but you are assigning some other values.

    You need to debug the code and find out that piece of code which is causing this error.

    Thanks,

    Girish S.

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,280 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,214 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Product updates

Dynamics 365 release plans