AX D365 FTP Interface with Third Party System - Part 3 Track Interface History

Hi,

AX D365 FTP Interface with Third Party System


Track Interface History

1. Create a history table 
2. Create a history form 



3. Add New Table Static method to create a history record


public class InterfaceHistory extends common
{
    public static void createInterfaceHistory(EDIMessageId messageId, EDITransmissionType transmissionType, EDIDirection direction, EDIErrorMessage  errorMessage, EDIStatus ediStatus)   {
        InterfaceHistory     interfaceHistory;

        ttsBegin;

        interfaceHistory.clear();
        interfaceHistory.initValue();
        interfaceHistory. EDIMessageId        = messageId;
        interfaceHistory. EDITransmissionType       = transmissionType;
        interfaceHistory. EDIDirection =direction;
        interfaceHistory. EDIErrorMessage =errorMessage;
        interfaceHistory. EDIStatus =ediStatus;
        interfaceHistory.insert();

        ttsCommit;
              
    }


}

4. Call Above method in FTP xml generation 

InterfaceHistory::createInterfaceHistory(MessageId,transmissionType,direction,errorMessage,ediStatus);

5.  History Output



Comments