RegOpenKeyEx返回5,在线急等
代码如下,返回值是5,请各位大虾分析下是什么原因
function TExcelCtr.isSetUpExel: Boolean;
var
TmepKEY : hKey;
Ret : Double;
begin
Result := False;
Ret :=RegOpenKeyEx(HKEY_CLASSES_ROOT,'Excel.Application',0,KEY_ALL_ACCESS,TmepKEY);
Try
if ret =ERROR_SUCCESS then Result := True;
Finally
RegCloseKey(TmepKEY);
end;
end;
操作系统 windows 2000 ,office 2003
肯定是有安装excel的