简体   繁体   中英

VBA: user-defined type not defined MSXML2.DOMDocument60

I am to prepare a demo for Reporting. For this we need to use VBA. We have to display some data from Reporting tool using ODATA and update the data via web service.

Blog to Consume ODATA using VBA

I write the same code , But I am getting Compile error : user-defined type not defined . I have added reference as defined in the blog , See the Image of the code and Reference below.

错误代码

参考

Can anybody guide how solve this ?

Thank and Regards

Should the line be

Set objXmlHttp = New MSXML2.XMLHTTP60

?

Failing that, looking in my registry, I see that MSXML2.XMLHTTP has CLSID {F6D90F16-9C73-11D3-B32E-00C04F990BB4} and the InprocServer32 for this class is %SystemRoot%\\System32\\msxml3.dll

If the code mandates that you use MSXML2.XMLHTTP you could try adding %SystemRoot%\\System32\\msxml3.dll as a project reference (or the dll that hosts MSXML2.XMLHTTP on your PC)

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM