delphi判断电脑是否安装了excel

uses Registry; procedure TForm1.Button1Click(Sender: TObject); var Reg:TRegistry; begin Reg:=TRegistry.Create; Reg.RootKey:=HKEY_CLASSES_ROOT; if Reg.OpenKey('/Excel.Sheet/CurVer',False) then showMessage('Excel 已安裝') else showMessage('Excel 沒安裝'); Reg.Free; end;

你可能感兴趣的:(Excel,Delphi)