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 :
Small and medium business | Business Central, N...
Suggested answer

How to bypass "Auto. Accept Transactions" when posting Intercompany Journals via AL Code

(3) ShareShare
ReportReport
Posted on by 77
Hi All,
 
In Business Central, when an Intercompany Journal is posted, the system checks the "Auto. Accept Transactions" setting on the IC Partner card. If this flag is enabled, the transactions are automatically accepted into the partner company’s inbox. I want to bypass this via AL Code.
 
 
Problem Statement -

In my scenario, I want to bypass this behavior — meaning the transactions should be sent to the IC Inbox, and gets automatically accepted, regardless of whether the partner’s "Auto. Accept Transactions" setting is enabled or not. I need this to work on one IC Journal Template and Batch only.

Has anyone implemented a solution or customization to override this logic in the Partner Company?

Also, I have already traversed the whole IC Journal Posting, and I got to see that this is checked in the codeunit 790 - "IC Inbox Outbox Subscribers", but there is no IsHandled variable for skipping this part for me.

[EventSubscriber(ObjectType::Report, Report::"Move IC Trans. to Partner Comp", 'OnICInboxTransactionCreated', '', false, false)]
    local procedure AcceptOnAfterInsertICInboxTransaction(var Sender: Report "Move IC Trans. to Partner Comp"; var ICInboxTransaction: Record "IC Inbox Transaction"; PartnerCompanyName: Text)
    var
        ICPartner: Record "IC Partner";
        TempRegisteredPartner: Record "IC Partner" temporary;
        FeatureTelemetry: Codeunit "Feature Telemetry";
        ICMapping: Codeunit "IC Mapping";
        ICDataExchange: Interface "IC Data Exchange";
    begin
        ICPartner.SetRange("Inbox Details", PartnerCompanyName);
        if not ICPartner.FindFirst() then
            exit;

        ICDataExchange := ICPartner."Data Exchange Type";
        ICDataExchange.GetICPartnerFromICPartner(ICPartner, TempRegisteredPartner);

        FeatureTelemetry.LogUptake('0000IIX', ICMapping.GetFeatureTelemetryName(), Enum::"Feature Uptake Status"::Used);
        FeatureTelemetry.LogUsage('0000IIY', ICMapping.GetFeatureTelemetryName(), 'IC Inbox Transaction Created');

        if TempRegisteredPartner."Auto. Accept Transactions" then
            if not IsICInboxTransactionReturnedByPartner(ICInboxTransaction."Transaction Source") then
                ICDataExchange.EnqueueAutoAcceptedICInboxTransaction(ICPartner, ICInboxTransaction);
    end;
 
I have the same question (0)
  • Aman Kakkar Profile Picture
    77 on at
    How to bypass "Auto. Accept Transactions" when posting Intercompany Journals via AL Code
    Hi Suresh, Thanks for your response.
     
    That was my question - how to make the changes in that Temporary record or to completely bypass the Job Queue logic that standard uses. Currently, I do not have any privilege to make any changes in this process. Can you share a code snippet if possible, as it will help me a bit more to understand the approach?
     
    Thanks again.
  • Suggested answer
    Suresh Kulla Profile Picture
    49,800 Super User 2025 Season 2 on at
    How to bypass "Auto. Accept Transactions" when posting Intercompany Journals via AL Code
    It uses the interface to retrieve the Registered Partner. If you can implement the IC Data Exchange Partner interface to update the GetICPartnerSetup, you can adjust the boolean on the Temporary record. Try that method.

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…

Andrés Arias – Community Spotlight

We are honored to recognize Andrés Arias as our Community Spotlight honoree for…

Leaderboard > Small and medium business | Business Central, NAV, RMS

#1
Nimsara Jayathilaka. Profile Picture

Nimsara Jayathilaka. 3,666

#2
Sumit Singh Profile Picture

Sumit Singh 2,885

#3
Rishabh Kanaskar Profile Picture

Rishabh Kanaskar 2,293

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans