Hi
please help and guide me
how can i change details office file ?
By using Microsoft Office COM abilities.
program project1;
{$APPTYPE CONSOLE}
uses
SysUtils, ComObj, ActiveX;
procedure ExcelMetadata;
var
ExcelApp, Workbook, Worksheet: OLEVariant;
begin
ExcelApp := CreateOleObject('Excel.Application');
try
ExcelApp.Visible := False;
// path MUST be absolute
Workbook := ExcelApp.Workbooks.Open(ExtractFilePath(ParamStr(0)) + 'demo.xlsx');
Worksheet := Workbook.Worksheets[1];
WriteLn('Author: ' + Workbook.BuiltInDocumentProperties('Author').Value);
WriteLn('By hitting return, Author name will be "Lazarus COM" !');
ReadLn;
Workbook.BuiltInDocumentProperties('Author').Value := 'Lazarus COM';
Workbook.Save;
Workbook.Close;
finally
ExcelApp.Quit;
end;
end;
begin
CoInitialize(nil);
try
ExcelMetadata;
finally
CoUninitialize;
end;
ReadLn;
end.
If you got no Excel, I can't help.