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

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Suggested answer

How to Add Customer reference in customer statement report

(0) ShareShare
ReportReport
Posted on by 786
Hi
I try to add customer reference in customer statement report 
Using the following code :
class CustAccountStatmentExtHelper
{
   
    /// <summary>
    ///
    /// </summary>
    /// <param name="sender"></param>
    /// <param name="e"></param>
    [DataEventHandler(tableStr(CustAccountStatementExtTmp), DataEventType::Inserting)]
    public static void CustAccountStatementExtTmp_onInserting(Common sender, DataEventArgs e)
    {
        CustAccountStatementExtTmp  CustAccountStatementExtTmp;
  
        CustAccountStatementExtTmp=sender;
        CustAccountStatementExtTmp.CustRef_ANS = SalesTable::find(CustInvoiceJour::findFromCustTrans(custAccountStatementExtTmp.CustTrans_Invoice,custAccountStatementExtTmp.CustTrans_TransDate,custAccountStatementExtTmp.AccountNum).SalesId).CustomerRef;
       
    }
}
but not showing me any Value after deployment ..
Is there another way to write code?

 
I have the same question (0)
  • Abhinay Tharwal Profile Picture
    1,213 on at
    RE: How to Add Customer reference in customer statement report

    Hi Hawraa,

    Please check which table is assigned to the tablix on the design side.

    Regards,

    Abhinay

  • Hawra Profile Picture
    786 on at
    RE: How to Add Customer reference in customer statement report

    I try step 1 , it's correct don't call also test value so I thing There is an incomplete step I do not know what

    I use this step in link to add this filed so can you tell me how to call this filed in DP Class

    community.dynamics.com/.../customize-design-and-business-logic-of-standard-ssrs-report-in-d365-f-amp-o

  • Suggested answer
    Abhinay Tharwal Profile Picture
    1,213 on at
    RE: How to Add Customer reference in customer statement report

    Hi Hawraa,

    Please try this and reply the result here:

    1. Assign some random text to the field (like "Test value"), compile/ build and deploy the report then run it.

    2. Check which table is assigned to the tablix in the SSRS report.

    3. As Nikolaos suggested share screenshot(s)

    Regards,

    Abhinay

  • nmaenpaa Profile Picture
    101,160 Moderator on at
    RE: How to Add Customer reference in customer statement report

    Could you share a screenshot from the debugger where we can see that a value is assigned to your field?

    Also, did you add this field to the query as suggested?

  • Hawra Profile Picture
    786 on at
    RE: How to Add Customer reference in customer statement report

    I already deployed but still same show new column but without value

  • WillWU Profile Picture
    22,359 on at
    RE: How to Add Customer reference in customer statement report

    Hi Hawraa,

    So you just need to deploy your report.

    Please try it.

    Any problems please let me know.

  • Hawra Profile Picture
    786 on at
    RE: How to Add Customer reference in customer statement report

    Dear Willful

    this is no CLI last in D365 so how I can maked

  • WillWU Profile Picture
    22,359 on at
    RE: How to Add Customer reference in customer statement report

    Hi Hawrra,

    It seems that you have add the new field in your temporary.

    You can put your codes into the class 'CustAccountStatmentExtController' (Method: "insertCustAccountStatementExtTmp").

    And remember to add the field also to a query namend "CustAccountStatmentExt" and not only to the table.

    Refresh the datasource 'CustAccountStatementExtDS' and run an incremental CIL last.

  • Hawra Profile Picture
    786 on at
    RE: How to Add Customer reference in customer statement report

    yes I debug but still it's not showing me any data in this filed

    8666.png

    24748.png

  • Suggested answer
    nmaenpaa Profile Picture
    101,160 Moderator on at
    RE: How to Add Customer reference in customer statement report

    Did you debug it? Does your code succesfully populate value in your new field? Once you make sure you have data in that field, please check that you added this field in the report design, and that you are using that same design in the printing.

    If you still have issues, please share us more info. Thanks!

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Mansi Soni – Community Spotlight

We are honored to recognize Mansi Soni as our August 2025 Community…

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Finance | Project Operations, Human Resources, AX, GP, SL

#1
Sohaib Cheema Profile Picture

Sohaib Cheema 708 User Group Leader

#2
Martin Dráb Profile Picture

Martin Dráb 589 Most Valuable Professional

#3
Yng Lih Profile Picture

Yng Lih 553

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans