Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. XML / XSL
  4. error C2065: 'IXMLDOMDocument3' : undeclared identifier

error C2065: 'IXMLDOMDocument3' : undeclared identifier

Scheduled Pinned Locked Moved XML / XSL
helphtmlcomxmltutorial
2 Posts 2 Posters 4 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • E Offline
    E Offline
    Emiliano
    wrote on last edited by
    #1

    :confused:I am trying to write a simple program that loads an xml file but i can not link this program, I am following this tutorial http://msdn.microsoft.com/library/default.asp?url=/library/en-us/xmlsdk/htm/dom\_hdi\_30dv.asp Could any body help?

    #include #include #include #pragma comment(lib,"msxml2.lib")

    int main()
    {
    HRESULT hr;
    IXMLDOMDocument3 *pXMLDoc = NULL;
    IXMLDOMParseError * pObjError = NULL;
    BSTR bstr = NULL;
    VARIANT_BOOL status;
    VARIANT var;

    CoInitialize(NULL);
    
    hr = CoCreateInstance(CLSID\_DOMDocument40, 
                     NULL, 
                     CLSCTX\_INPROC\_SERVER, 
                     IID\_IXMLDOMDocument3,
                     (void\*\*)&pXMLDoc);
    
    return 0;
    

    }

    S 1 Reply Last reply
    0
    • E Emiliano

      :confused:I am trying to write a simple program that loads an xml file but i can not link this program, I am following this tutorial http://msdn.microsoft.com/library/default.asp?url=/library/en-us/xmlsdk/htm/dom\_hdi\_30dv.asp Could any body help?

      #include #include #include #pragma comment(lib,"msxml2.lib")

      int main()
      {
      HRESULT hr;
      IXMLDOMDocument3 *pXMLDoc = NULL;
      IXMLDOMParseError * pObjError = NULL;
      BSTR bstr = NULL;
      VARIANT_BOOL status;
      VARIANT var;

      CoInitialize(NULL);
      
      hr = CoCreateInstance(CLSID\_DOMDocument40, 
                       NULL, 
                       CLSCTX\_INPROC\_SERVER, 
                       IID\_IXMLDOMDocument3,
                       (void\*\*)&pXMLDoc);
      
      return 0;
      

      }

      S Offline
      S Offline
      Stephane Rodriguez
      wrote on last edited by
      #2

      Did you install the MSXML 4 SDK ? (see MS platform SDK site for the update). Once installed, you still need to add the path to the msxml2.lib file in either your project settings (additional library path), or your VisualStudio general directories (tools / options / directories).

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups