PHP User Warning: fetch_template() calls should be replaced by the vB_Template class. Template name: bbcode_highlight in ..../includes/functions.php on line 4197
Create ODBC-VBForums
Results 1 to 13 of 13

Thread: Create ODBC

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Sep 2005
    Posts
    138

    Create ODBC

    Hello everyone
    I searched planet source code for a code that create a System ODBC
    but all codes are doing ODBCs that asks for user name and password
    I want the authenticity with Windows NT authentication using the network login ID
    how can I do this ?
    Thanks

  2. #2
    Banned randem's Avatar
    Join Date
    Oct 2002
    Location
    Maui, Hawaii
    Posts
    11,385

    Re: Create ODBC

    Why do you need ODBC? You can use ADO code to connect without having the overhead and aggravation of ODBC setup.

  3. #3

    Thread Starter
    Addicted Member
    Join Date
    Sep 2005
    Posts
    138

    Re: Create ODBC

    Because the SQL Server is used by many clients on the network, an ODBC Connection setup needed to connect to the server.

  4. #4
    Super Moderator si_the_geek's Avatar
    Join Date
    Jul 2002
    Location
    Bristol, UK
    Posts
    40,885

    Re: Create ODBC

    If this is just for your VB program, it isn't needed at all (and is arguably a bad idea anyway).

    See the Connection Strings link in my signature for examples of what you need to connect without DSN's.

  5. #5

    Thread Starter
    Addicted Member
    Join Date
    Sep 2005
    Posts
    138

    Re: Create ODBC

    I need to know how to create a system dsn regardless of it is a bad idea, I need to know how.

  6. #6
    Super Moderator si_the_geek's Avatar
    Join Date
    Jul 2002
    Location
    Bristol, UK
    Posts
    40,885

    Re: Create ODBC

    Well I suggest you search the forums for the code, as most of us stopped using DSN's years ago.

  7. #7

    Thread Starter
    Addicted Member
    Join Date
    Sep 2005
    Posts
    138

    Re: Create ODBC

    ty sir

  8. #8
    Hyperactive Member
    Join Date
    Jun 2000
    Location
    NY
    Posts
    497

    Re: Create ODBC

    I wrote some code to lookup and create an ODBC once. It's all registry settings. Create an ODBC yourself the way you want, then check out the values in HKLM\SOFTWARE\ODBC\... under the DSN name you created.

    You do need to know the path to the driver that is being used, i.e. full path to sqlsrv32.dll for sql server, as it is one of the registry values. If you really want code, I can post what I've got.
    end war
    stop greed

  9. #9
    VB Guru ganeshmoorthy's Avatar
    Join Date
    Dec 2005
    Location
    Sharjah, United Arab Emirates
    Posts
    3,031

    Re: Create ODBC

    this will create a DSN
    VB Code:
    1. 'Creating the DSN
    2.     StrAttribs = "Description="ODBC Driver Description" & Chr$(13) & "DBQ=" & DBName
    3.    rdoEngine.rdoRegisterDataSource "YourODBCName", "Microsoft Access Driver (*.Mdb)", True, StrAttribs
    If an answer to your question has been helpful, then please, Rate it!

    Have done Projects in Access and Member management systems using BioMetric devices, Smart cards and BarCodes.


  10. #10
    Hyperactive Member
    Join Date
    Jun 2000
    Location
    NY
    Posts
    497

    Re: Create ODBC

    Wow. I wish I knew that 5 years ago! What object is rdoEngine from (remote data objects?)
    end war
    stop greed

  11. #11

  12. #12
    VB Guru ganeshmoorthy's Avatar
    Join Date
    Dec 2005
    Location
    Sharjah, United Arab Emirates
    Posts
    3,031

    Re: Create ODBC

    can you post the codes that connecting/creating ODBC for AS400
    If an answer to your question has been helpful, then please, Rate it!

    Have done Projects in Access and Member management systems using BioMetric devices, Smart cards and BarCodes.


  13. #13
    Fanatic Member sessi4ml's Avatar
    Join Date
    Nov 2006
    Location
    Near San Francisco
    Posts
    952

    Re: Create ODBC

    Quote Originally Posted by ganeshmoorthy View Post
    can you post the codes that connecting/creating ODBC for AS400
    All the code I found, located, created is in my signature...I wrote ? 2004?

    With the correct use -profile and password...it should work

    Glad to help
    MLS

Posting Permissions

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



Featured


Click Here to Expand Forum to Full Width