Skip to content

KVSMEDDIIMDocumentMgt#

Events#

OnBeforeArchiveEPrescriptionDataToDMS(Record KVSMEDEDocumentData, Record KVSMEDDIIMDocument, Boolean, Text) :#

Summary: Raised before archiving e-prescription data to the document management system (DMS). Allows subscribers to implement custom archiving logic or override the default behavior.

[IntegrationEvent(false, false)]
local procedure OnBeforeArchiveEPrescriptionDataToDMS(var KVSMEDEDocumentData: Record "KVSMEDEDocumentData"; var KVSMEDDIIMDocument: Record "KVSMEDDIIMDocument"; var IsHandled: Boolean; var ErrorReturnValue: Text): 
[EventSubscriber(ObjectType::Codeunit, Codeunit::"KVSMEDDIIMDocumentMgt", 'OnBeforeArchiveEPrescriptionDataToDMS', '', false, false)]
local procedure DoSomethingOnBeforeArchiveEPrescriptionDataToDMS(var KVSMEDEDocumentData: Record "KVSMEDEDocumentData"; var KVSMEDDIIMDocument: Record "KVSMEDDIIMDocument"; var IsHandled: Boolean; var ErrorReturnValue: Text)
begin
end;

Parameters:

  • KVSMEDEDocumentData: The e-document data to be archived.
  • KVSMEDDIIMDocument: The underlying DIIM document associated with the e-prescription data.
  • IsHandled: Set to true to prevent the default DMS archiving logic from executing.
  • ErrorReturnValue: The error message to return if archiving fails. Set by subscribers when IsHandled is true.