uses
ComObj;
procedure TForm25.Button1Click(Sender: TObject);
var
XLS : Variant;
begin
try
XLS := CreateOleObject('Excel.Application');
XLS.Visible := True;
XLS.WorkBooks.Open('book1.xls');
XLS.Range['F5'].AddComment('Hello, World!');
except
end;
XLS := UnAssigned;
end;