DevExpress4Delphi
v1.0.8
DevExpress4Delphi is a class helper for DevExpress components.
[Optional] For ease I recommend using the Boss (Dependency Manager for Delphi) for installationboss install github.com/viniciussanchez/DevExpress4Delphi
Add the following folders to your project, in Project > Options > Resource Compiler > Directories and Conditionals > Include file search path
../DevExpress4Delphi/src
You need to use DevExpress.Helper
uses DevExpress.Helper;You can pass two parameters:
AOpenFileAfter: Open file after export. Default is True.AExpand: Expand records. Default is True.begin
cxGrid1.ExportToExcel();
end;begin
cxGrid1.ExportToHTML();
end;begin
cxGrid1.ExportToXML();
end;begin
cxGrid1.ExportToTXT();
end;You can pass parameter:
AMaxWidth: Refers the maximum column width.begin
cxGrid1DBTableViewNAME.Resize();
end;Exporting to excel:

Adjusting the size of the column so that there is no white space on the grid:
