#include <msxml2.h>
#include <iostream.h>int main(void){
    CoInitialize(NULL);    IXMLDOMDocument2* pDoc=NULL;
    HRESULT hr=CoCreateIntance(CLSID_DOMDocument,NULL,IID_IXMLDOMDocument2,(void**)&pDoc);
    IXMLDOMElement* pElement=NULL;
    hr=pDoc->get_documentElement(*pElement);
    pElement->Release();
    pElement=NULL;    char buf[128];
    DWORD dwStatus=FormatMessage(
            FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_ARGUMENT_ARRAY,
            NULL, // LPCVOID pointer to message source
   hr, // DWORD requested message identifier
   LANG_NEUTRAL, // DWORD language identifier for message
   buf, // LPTSTR pointer to message buffer
   127, // DWORD maximum size of message buffer
   NULL // va_list *Arguments address of array of message 
            ); 
    cout << buf << endl;
    pDoc->Release();
    pDoc=NULL;
   
    CoUninitialize();
    return 0;
}上面的程序编译条件:msxml2.h,msxml2.lib编译通过,但运行时 hr=pDoc->get_documentElement(*pElement); 出错.
报 "功能错误".......这是为啥啊??????? 请各位帮忙,
急,急.................