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
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. ADO Connection ptr under Windows 7 fails in Windowx XP

ADO Connection ptr under Windows 7 fails in Windowx XP

Scheduled Pinned Locked Moved C / C++ / MFC
databasec++sql-serversysadmintools
2 Posts 2 Posters 0 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.
  • A Offline
    A Offline
    aaandrei
    wrote on last edited by
    #1

    Hello everybody, Currently all my C++ project are on a Windows XP machine. For database connections I’m using ado. In stdafx.h I have lines: #import "c:\Program Files\Common Files\system\ado\msado15.dll" rename_namespace( "ado" ) rename("EOF", "ADOEOF") #import "C:\Program Files\Microsoft SQL Server\80\Tools\Binn\Resources\1033\sqldmo.rll" no_namespace And when it’s required I call ado::_ConnectionPtr pConn = NULL; hr = pConn.CreateInstance( __uuidof( ado::Connection ) ); Everything has been working fine. But now I’m moving all my projects to Windows 7 machine. And it appears, that created .exe files are working fine on Windows 7 machine but on Windows XP ado pointer could not be created. hr = pConn.CreateInstance( __uuidof( ado::Connection ) ); doesn’t create valid connection object. Thank you in advance, any suggestions will be appreciated

    J 1 Reply Last reply
    0
    • A aaandrei

      Hello everybody, Currently all my C++ project are on a Windows XP machine. For database connections I’m using ado. In stdafx.h I have lines: #import "c:\Program Files\Common Files\system\ado\msado15.dll" rename_namespace( "ado" ) rename("EOF", "ADOEOF") #import "C:\Program Files\Microsoft SQL Server\80\Tools\Binn\Resources\1033\sqldmo.rll" no_namespace And when it’s required I call ado::_ConnectionPtr pConn = NULL; hr = pConn.CreateInstance( __uuidof( ado::Connection ) ); Everything has been working fine. But now I’m moving all my projects to Windows 7 machine. And it appears, that created .exe files are working fine on Windows 7 machine but on Windows XP ado pointer could not be created. hr = pConn.CreateInstance( __uuidof( ado::Connection ) ); doesn’t create valid connection object. Thank you in advance, any suggestions will be appreciated

      J Offline
      J Offline
      Jochen Arndt
      wrote on last edited by
      #2

      With Windows 7 SP1 or installed KB983246, the ADO DLL has been changed. See http://support.microsoft.com/kb/2517589/en-us[^]. Solution 1 (install updated libraries) See http://blogs.msdn.com/b/psssql/archive/2011/10/03/yes-we-made-a-mistake-and-are-finally-going-to-fix-it.aspx[^] and http://support.microsoft.com/kb/2640696[^] to download new libraries. Solution 2 (excluding and renaming changed UUIDs) See Your ADO is broken[^]. Use this only when your developing machine uses Windows 7 SP1.

      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