***...müködik
és igazad volt rohadt egyszerű
procedure TForm1.Button1Click(Sender: TObject);
var
Exp: TFPSExport;
ExpSettings: TFPSExportFormatSettings;
TheDate: TDateTime;
begin
Dbf1.First; //assume we have a dataset called FDataset
Exp := TFPSExport.Create(nil);
ExpSettings := TFPSExportFormatSettings.Create(true);
try
ExpSettings.ExportFormat := efXLS; // choose file format
ExpSettings.HeaderRow := true; // include header row with field names
Exp.FormatSettings := ExpSettings; // apply settings to export object
Exp.Dataset:=Dbf1; // specify source
Exp.FileName := 'd:\datadump.xls';
Exp.Execute; // run the export
finally
Exp.Free;
ExpSettings.Free;
end;
end;
KÖSZI!