Axapta x++ code, that allow us to filter XLSX and CSV files in a dialog box...
This is useful if you want to show only this type of files in a selection.
public Object dialog()
{
DialogRunbase dialog = super();
#AviFiles
#Excel
dialogFilename = dialog.addField(typeId(FilenameOpen));
dialog.filenameLookupFilter(["@SYS28576",#XLSX,"@SYS100852","*.csv"]);
dialog.filenameLookupTitle("Upload from EXCEL/CSV");
dialogFilename.value(filename);
return dialog;
}
This is useful if you want to show only this type of files in a selection.
public Object dialog()
{
DialogRunbase dialog = super();
#AviFiles
#Excel
dialogFilename = dialog.addField(typeId(FilenameOpen));
dialog.filenameLookupFilter(["@SYS28576",#XLSX,"@SYS100852","*.csv"]);
dialog.filenameLookupTitle("Upload from EXCEL/CSV");
dialogFilename.value(filename);
return dialog;
}
No comments:
Post a Comment