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

Notifications

Announcements

Community site session details

Community site session details

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

DATETime field

(0) ShareShare
ReportReport
Posted on by

Hello everyone,

I have a customer requirement: 

I want to add a new date time field in custConfirmJour like ConfirmDate field + it gets the time of the confirmation transaction in the system for the sales order.  I've tried to insert it in the classes:

1. SalesFormletterParmData.

2.SalesConfirmJournalCreate\createJournalHeader.

but it returns to me errors while clicking the confirmation button of the sales order.

Can somenone let me know where can i insert this field?

Best regards.

I have the same question (0)
  • Suggested answer
    nmaenpaa Profile Picture
    101,166 Moderator on at

    You need to start by having a succesful x++ build without any errors. Then full CIL. Then db sync.

    There's no point for you to test anything in this system if the codebase is in a broken state!

    I strongly suggest you set up a nightly build in your dev system. This way you will catch any errors right away and can fix them the next morning.

  • Community Member Profile Picture
    on at

    58332.Error.png

  • nmaenpaa Profile Picture
    101,166 Moderator on at

    Try AOS restart, full x++ compile and CIL generation. In general you should do these every night in your dev system.

  • Community Member Profile Picture
    on at

    I did it but the error displays again.

  • Suggested answer
    nmaenpaa Profile Picture
    101,166 Moderator on at

    Try to clear your usage data and then run it again.

  • Community Member Profile Picture
    on at

    Hello,
    1. I have added a dateTime field in the tables CustConfirmJour and salesParmTable whose extended data type is transDateTime.
    2. I have added a method named "updateDateTime" in the class SalesConfirmJournalCreate that returns the date time field of salesParmTable.
    3. i have added the line code :
    custConfirmJour.ConfirmDateTime = salesParmTable.TransDateTime;
    under the method initJournalHeader method of the class SalesConfirmJournalCreate.
    4. I have added in the run method of the class SalesFormLetter the line: this.transDateTime(DateTimeUtil::getSystemDateTime());
    5. I have added the method TransDateTime() in the class FormLetterServiceController.
    6. I have added the parmTransDate method in the class FormLetterContract
    7. Finally the line code on the MainOnServer of salesFormLetter class:
    salesFormLetter.transDateTime(DateTimeUtil::getSystemDateTime());


    I have this error :

    7651.Error.png

    Best regards.

  • nmaenpaa Profile Picture
    101,166 Moderator on at

    Let's start by sharing the relevant information that is required to identify problems in your code and analyze the error:

    1) Your code

    2) The error message

    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

News and Announcements

Season of Giving Solutions is Here!

Quick Links

Responsible AI policies

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

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

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

#1
Abhilash Warrier Profile Picture

Abhilash Warrier 867 Super User 2025 Season 2

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 514 Super User 2025 Season 2

#3
BillurSamdancioglu Profile Picture

BillurSamdancioglu 348 Most Valuable Professional

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans