Delphi is not registered properly XCom ActiveX
If you register XCom on some versions of Delphi,
may create an incorrect TLB file in the Delphi \\ imports directory and fail to deliver XComs return value normally.
In this case, the XCom API return value cannot be used normally.
You must correct the TLB file directly or copy the normal TLB file.
(Register XCom in another version of Delphi and copy the TLB file)