[Event Request] table 295 "Reminder Header" - InsertTextLines procedure
Why do you need this change?
Describe the request
The current change would benefit the fact that when inserting a ReminderLine inside the procedure InsertTextLines from the table 295 "Reminder Header", we can avoid breaking behavior by making the code extensible as it already was in the procedure: procedure InsertTextLines(var ReminderHeader: Record "Reminder Header"; var ReminderText: Record "Reminder Text"; var NextLineNo: Integer; LineSpacing: Integer)
Current:
procedure InsertTextLines(var LocalReminderHeader: Record "Reminder Header"; var ReminderAttachmentText: Record "Reminder Attachment Text"; LineType: Enum "Reminder Line Type"; var NextLineNumber: Integer; LineSpace: Integer)
var
ReminderAttachmentTextLine: Record "Reminder Attachment Text Line";
ReminderCommunication: Codeunit "Reminder Communication";
begin
if not ReminderAttachmentText.IsEmpty() then begin
....
ReminderLine.Description := ReminderCommunication.SubstituteBeginningOrEndingDescription(ReminderAttachmentTextLine.Text, ReminderTotal, MaxStrLen(ReminderLine.Description), LocalReminderHeader, FinChrgTerms);
ReminderLine.Insert();
until ReminderAttachmentTextLine.Next() = 0;
if LineType = Enum::"Reminder Line Type"::"Beginning Text" then
InsertBlankLine(ReminderLine."Line Type"::"Beginning Text");
end;
end;
Requested: Current:
procedure InsertTextLines(var LocalReminderHeader: Record "Reminder Header"; var ReminderAttachmentText: Record "Reminder Attachment Text"; LineType: Enum "Reminder Line Type"; var NextLineNumber: Integer; LineSpace: Integer)
var
ReminderAttachmentTextLine: Record "Reminder Attachment Text Line";
ReminderCommunication: Codeunit "Reminder Communication";
begin
if not ReminderAttachmentText.IsEmpty() then begin
....
ReminderLine.Description := ReminderCommunication.SubstituteBeginningOrEndingDescription(ReminderAttachmentTextLine.Text, ReminderTotal, MaxStrLen(ReminderLine.Description), LocalReminderHeader, FinChrgTerms);
OnInsertTextLinesOnBeforeRemLineInsert(LocalReminderHeader, ReminderLine, ReminderAttachmentText);
ReminderLine.Insert();
until ReminderAttachmentTextLine.Next() = 0;
if LineType = Enum::"Reminder Line Type"::"Beginning Text" then
InsertBlankLine(ReminderLine."Line Type"::"Beginning Text");
end;
end;
...
[IntegrationEvent(false, false)]
local procedure OnInsertTextLinesOnBeforeRemLineInsert(var ReminderHeader: Record "Reminder Header"; var ReminderLine: Record "Reminder Line"; var ReminderAttachmentText: Record "Reminder Attachment Text";)
begin
end;
Describe the request
We are requesting this event because our custom solution allows us to use placeholders to fill the Reminder Line Description by subscribing to the old event OnInsertTextLinesOnBeforeReminderLineInsert from the Table "Reminder Header" Internal work item: AB#591743
Thanks for reporting this. We agree, and we’ll publish a fix asap, either in an update for the current version or in the next major release. Please do not reply to this, as we do not monitor closed issues. If you have follow-up questions or requests, please create a new issue where you reference this one.
Build ID: 36603.
Hi Jesper, I think, there was a mistake in the requested event. There should be a ReminderAttachmentTextLine as a parameter in the event, instead of ReminderAttachmentText. Shall I create a new event request issue or this can be changed under this ticket id?
Thanks!
Could you create a follow-up issue? Then we'll revisit your request. Must have been a mistake on our end, I assume. Sorry about that!
Hello Jesper and Bogdan,
Thanks for the heads-up. I have submitted a new extensibility request: https://github.com/microsoft/ALAppExtensions/issues/29242
Have a nice day ahead!