CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    Aug 1999
    Location
    Southern California
    Posts
    10

    Provider and connection string

    Hi,

    I’m trying to connect to a FileMaker Pro 5.0 database through ADO.NET ODBC connection and have been having trouble trying to figure out what name to use for the provider in the connection string.

    In the past I have always used code like the code below to connect to SQL Server and have never had any problems.
    {
    string connectionString="Provider=SQLOLEDB.1;"+
    "Integrated Security=SSPI;"+
    "Persist Security Info=FALSE;"+
    "Initial Catalog=customers;"+
    "Data Source=(local)";

    OleDbConnection cn;
    cn=new OleDbConnection(connectionString);
    cn.Open();

    }

    I looked in the ODBC Data Source Administrator and saw the FileMaker Pro database driver installed as file FMFMP50.dll. But can’t determine the provider name from that. I also looked in the FileMaker Pro users manual and didn’t see it there either.

    Does anyone know of a way I can find out what provider names are registered on a machine?

    Thanks in advance,
    Larry

  2. #2
    Join Date
    Aug 1999
    Location
    Southern California
    Posts
    10

    Needed to download the .NET ODBC Provider

    Nevermind, it turns out I needed to download the Microsoft ODBC .NET Data Provider (Microsoft.Data.Odbc) and connect like this:

    OdbcConnection connection=new OdbcConnection();
    string connectionString="Driver={FileMaker Pro};";
    connection.ConnectionString=connectionString;
    connection.Open();

Posting Permissions

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





Click Here to Expand Forum to Full Width

Featured