Dear Stefan,
thank you for your question. We already investigating this issue. In the meanwhile you can also use the command "SHOW_EXPORT_DLG" in the messageport "ImportExport". This command shows a dialog for exporting models and attribute profiles. The dialog can be used for any export format (e.g. XML).The parameters for this command are defined as follows:
CC "ImportExport"
SHOW_EXPORT_DLG [ title:strValue ] [ multi-select:boolValue ] [ model-groups-selectable:boolValue ] [ filename:strValue ] [ filedescription:strValue ][ fileextension:strValue ] [ mode:dialogMode ] .
dialogMode"adl" | "xml" .
-->RESULT endbutton:EndButton filename:strValue modelids:idStrValue mgroupids:idStrValue attrprofids:idStrValue apgroupids:idStrValue with-models:boolValue with-referenced-models:boolValue with-mgroups:boolValue mgroups-recursive:boolValue with-attrprofs:boolValue with-referenced-attrprofs:boolValue with-apgroups:boolValue apgroups-recursive:boolValue .
EndButton :"ok" | "cancel" .
The default values are:
title: "ADL export - selection" (German: "ADL-Export - Auswahl")
filedescription: "ADL files" (German: "ADL-Dateien")
fileextension: "*.adl" mode:"adl"
By default, multiple models can be selected and model groups are selectable. Set parameter
multi-select:0 to allow just single selection. Set parameter
model-groups-selectable:0 to disable model group selection.
The parameter
mode is currently only used to attach the correct online help.
The bool result values
with-referenced-models and
with-referenced-attrprofs are just for information. They have not necessarily be evaluated by the export routine. The consequences of these options are already applied to the ID container values. The referenced models (if
with-referenced-models is true) are already included in
modelids. The referenced attribute profiles (if
with-referenced-attrprofs is true) are already included in attrprofids.
Hint: Some of the result parameter names contain minus signs ('-'). If you want to use a variable name containing one or more minus signs within an expression, you have to prevent the LEO compiler from interpreting them as minus operator by prefixing the variable name with a quotation mark ('?'). So, within an expression, instead of
with-referenced-models you have to write ?
with-referenced-models.
Below you can also find an example of the command
SHOW_EXPORT_DLG:
# 1. Model selection by user1CC "ImportExport" SHOW_EXPORT_DLG title:"SRL Export" multi-select:1 filedescription:"SRL file" fileextension:"*.srl" mode:"adl"
2SET lSelectedModelIDs: (modelids)
3SET sExportSRLFileName: (filename)
4SET sExportADLFileName: (replall(filename, ".srl", "") + ".adl")
# 2. Export model in ADL formatCC "ImportExport"
1ADL_EXPORT (sExportADLFileName) modelids: (lSelectedModelIDs)
Kind Regards,
Mehmet