Friday, April 22, 2022

Power Automate Business Central Journal Line Import Error

by Steve Endow

NOTE:  I'm encountering this error as of April 22, 2022.  If this ends up being a bug in the Power Automate BC connector that is fixed, I'll post an update.


A customer is interested in importing General Journals into Dynamics 365 Business Central using Power Automate.

Simple, right?  Just one Power Automate flow, right?  How hard could it be, right?

Well, it depends.

This is the error that I get in my Power Automate environment.

You must specify a journal batch ID or a journal ID to get a journal line

When I ask why it doesn't work, I get responses that seem to indicate that it should work.

"It works fine for me"

"You must be doing it wrong"

"Did you try doing it this way?"

But no matter what I try, the flow gives me the same error:

ErrorCode: Application_DialogException  You must specify a journal batch ID or a journal ID to get a journal line.  

Thursday, April 7, 2022

Resolving Business Central AL Warning AL0603 - Implicit conversion to a value of type Enum

 by Steve Endow

While copying a standard Business Central Web API page to a new project to create a customized version of the API page, I encountered this compiler warning:


AL0603 - Implicit Conversion to a value of type Enum


An implicit conversion is being performed from a value of type 'Integer' to a value of type 'Enum "Attachment Entity Buffer Document Type"'. This conversion can lead to unexpected runtime issues. This warning will become an error in a future release.AL AL0603
(field) "Document Type": Enum "Attachment Entity Buffer Document Type"


I am vaguely familiar with this error, and I think I resolved it months ago in a different Business Central project, but I completely forgot how I figured it out and how I resolved it.  So I'm writing this post to remind me when I forget again in 6 months.