سلام
یه روش :
var
ClassID: TCLSID;
strOLEObject: string;
begin
strOLEObject := 'Excel.Application';
if (CLSIDFromProgID(PWideChar(WideString(strOLEObject )), ClassID) = S_OK)
then
begin
<application is installed>
end
else
begin
<application is NOT installed>
end
end;
یه روش دیگه :
try
ExcelApp := GetActiveOleObject('Excel.Application');
except
try
// If no instance of Word is running, try to Create a new Excel Object
ExcelApp := CreateOleObject('Excel.Application');
except
ShowMessage('Cannot start Excel/Excel not installed ?');
Exit;
end;
end;