Results 1 to 6 of 6
  1. #1
    marianne is offline Competent Performer
    Windows XP Access 2003
    Join Date
    Mar 2009
    Location
    Asia Pacific Region
    Posts
    150

    how to automate odbc connect creation to connect access to sql server


    Hi I would like to ask what are the steps how to create odbc connection without going to control panel but just using the codes to connect access to sql tables. thanks.

  2. #2
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 10 Access 2013 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    I don't know if this link will help but it is at least something.

  3. #3
    marianne is offline Competent Performer
    Windows XP Access 2003
    Join Date
    Mar 2009
    Location
    Asia Pacific Region
    Posts
    150
    is that it? i dont need to go to control panel anymore to create the odbc?

  4. #4
    Matrix's Avatar
    Matrix is offline Admin
    Windows 10 Access 2010 64bit
    Join Date
    Jan 2005
    Posts
    517
    Here is a VBscript to do this.

  5. #5
    thhui is offline Competent Performer
    Windows XP Access 2002 (version 10.0)
    Join Date
    Feb 2009
    Posts
    235
    Try this using ADO when connecting to Microsoft SQL Server.

    Code:
    Dim Conn As ADODB.Connection
    Set Conn = New ADODB.Connection
    Conn.ConnectionString = "Driver={SQL Server};Description=sqldemo;SERVER=127.0.0.1;UID=LoginID;PWD=Password; DATABASE=Database_Name;"
    Conn.Open

  6. #6
    marianne is offline Competent Performer
    Windows XP Access 2003
    Join Date
    Mar 2009
    Location
    Asia Pacific Region
    Posts
    150
    thank you for your reply. i will try your suggestions.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. how to connect ms access to sql
    By marianne in forum Access
    Replies: 22
    Last Post: 03-24-2009, 11:14 AM
  2. Replies: 0
    Last Post: 03-09-2009, 12:20 PM
  3. connect from access to sql
    By kathyc in forum Programming
    Replies: 0
    Last Post: 09-28-2008, 12:50 PM
  4. very slow when connect to access 2000
    By pureland in forum Access
    Replies: 0
    Last Post: 10-23-2007, 05:42 AM
  5. Replies: 3
    Last Post: 04-05-2006, 04:17 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums