Results 1 to 2 of 2

Thread: DB connction

  1. #1
    Join Date
    Oct 2003

    Unanswered: DB connction

    My VC application read and writes data from and to a MS Excel workbook,using the Microsoft.Jet.OLEDB.4.0 provider as follow:

    strDB.Format("Provider=Microsoft.Jet.OLEDB.4.0;Dat a Source=%s;", this->m_DBPath);

    } catch (_com_error e) {

    CString strTemp;
    strTemp.Format("error cause£ºDB connection failed£¡\n error info£º%s\n error description£º%s\n",e.ErrorMessage(),e.Description( ));

    Having edited on Win2000, let it run on Win98.To my great surprise,many PCs (All of the PCs have installed DB Access)thrown out like this:

    error cause£ºDB connection failed£¡
    error info£ºpointer invalid.
    error description£º

    I donn't know why. who can pass me the key?

  2. #2
    Join Date
    Sep 2003
    Do you have that provider installed? This sounds like a MDAC issue ... Make sure you have the same MDAC on that target machine as your development machine.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts