Skip to content

Handle failure to manually create E-Document from posted doc with no …#8183

Open
georgepomazkov wants to merge 2 commits into
microsoft:mainfrom
georgepomazkov:bugs/8181-verify-manual-edoc-creation
Open

Handle failure to manually create E-Document from posted doc with no …#8183
georgepomazkov wants to merge 2 commits into
microsoft:mainfrom
georgepomazkov:bugs/8181-verify-manual-edoc-creation

Conversation

@georgepomazkov
Copy link
Copy Markdown

@georgepomazkov georgepomazkov commented May 18, 2026

Fixes message 'The e-document has been created.' being shown to user when the e-document was not in fact created.

What & why

In cases when the e-document could not be manually created from a posted document page with no explicit error, the system would still tell the user that 'The e-document has been created.'.

The fix implements a check in the underlying procedure CreateEDocumentFromPostedDocumentPage() to verify that the number of e-documents linked to this posted document has actually increased, and only in this case the procedure will exit with true. Otherwise, the action code calling this procudes from the posted document page will display message 'The e-document could not be created.'.

Linked work

Fixes #8181

How I validated this

  • I read the full diff and it contains only changes I intended.
  • I built the affected app(s) locally with no new analyzer warnings.
  • I ran the change in Business Central and confirmed it behaves as expected.
  • I added or updated tests for the new behavior, or explained below why none are needed.

What I tested and the outcome (required — be specific: scenarios, commands, screenshots for UI changes)

Manually tested the case for posted sales invoice described in the issue, the system showed the following message when the e-document was not created due to the document type not being supported by the E-Document Service and no explicit error being thrown.

image

Risk & compatibility

None.

@georgepomazkov georgepomazkov requested a review from a team as a code owner May 18, 2026 10:14
@github-actions github-actions Bot added AL: Apps (W1) Add-on apps for W1 From Fork Pull request is coming from a fork labels May 18, 2026
@georgepomazkov
Copy link
Copy Markdown
Author

@microsoft-github-policy-service agree

@JesperSchulz JesperSchulz added the Integration GitHub request for Integration area label May 18, 2026
JesperSchulz
JesperSchulz previously approved these changes May 18, 2026
Comment thread src/Apps/W1/EDocument/App/src/Processing/EDocumentProcessing.Codeunit.al Outdated
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

AL: Apps (W1) Add-on apps for W1 From Fork Pull request is coming from a fork Integration GitHub request for Integration area

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: [E-Document] The system tells that the e-document has been created from a posted document when it was not actually created

3 participants