ALAppExtensions icon indicating copy to clipboard operation
ALAppExtensions copied to clipboard

[Event Request] Table Reminder Comment Line - OnBeforeCopyComments

Open MattiLE opened this issue 7 years ago • 0 comments

Hi AL-team,

we have advanced comment logic and need a additional publisher. Can you add the Publisher as follows?

[External] CopyComments(FromType : Integer;ToType : Integer;FromNumber : Code[20];ToNumber : Code[20])
// NEW BEG
IsHandled := FALSE;
OnBeforeCopyComments(ReminderCommentLine,ToType,IsHandled,FromType,FromNumber,ToNumber);
IF IsHandled THEN
  EXIT;
// NEW END
ReminderCommentLine.SETRANGE(Type,FromType);
ReminderCommentLine.SETRANGE("No.",FromNumber);
IF ReminderCommentLine.FINDSET THEN
  REPEAT
    ReminderCommentLine2 := ReminderCommentLine;
    ReminderCommentLine2.Type := ToType;
    ReminderCommentLine2."No." := ToNumber;
    ReminderCommentLine2.INSERT;
  UNTIL ReminderCommentLine.NEXT = 0;

LOCAL [IntegrationEvent] OnBeforeCopyComments(VAR ReminderCommentLine : Record "Reminder Comment Line";ToType : Integer;VAR IsHandled : Boolean;FromType : Integer;FromNumber : Code[20];ToNumber : Code[20])

MattiLE avatar Jul 25 '19 13:07 MattiLE