[Event Request] Page 5620 - Fixed Asset Picture - OnExportFileOnAfterSetExportPath
Dear ALAppExtensions team,
Through this issue we would like to request adding event publisher OnExportFileOnAfterSetExportPath in Page 5620 Fixed Asset Picture with the following signature:
[IntegrationEvent(false, false)]
local procedure OnExportFileOnAfterSetExportPath(FixedAsset: Record "Fixed Asset",
var ToFile: Text,
var ExportPath: Text)
begin
end;
with VAR parameters ToFile and ExportPath.
which would be called as follows in action ExportFile:
action(ExportFile)
{
ApplicationArea = Basic, Suite;
Caption = 'Export';
Enabled = DeleteExportEnabled;
Image = Export;
ToolTip = 'Export the picture to a file.';
trigger OnAction()
var
FileManagement: Codeunit "File Management";
ToFile: Text;
ExportPath: Text;
begin
TestField("No.");
TestField(Description);
ToFile := StrSubstNo('%1 %2.jpg', "No.", Description);
ExportPath := TemporaryPath + "No." + Format(Image.MediaId);
// >>>> New >>>>>>>>>>>>>>>>
OnExportFileOnAfterSetExportPath(Rec, ToFile, ExportPath);
// <<<< New <<<<<<<<<<<<<<<<
Image.ExportFile(ExportPath);
FileManagement.ExportImage(ExportPath, ToFile);
end;
}
It is required so that the path format as well as the file name format can be overridden.
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: 41251.