Results 1 to 12 of 12

Thread: client server in vb6 and microsoft sql server 2000

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Feb 2007
    Location
    Manila
    Posts
    85

    client server in vb6 and microsoft sql server 2000

    hi guys.. i am currently doing a project that needs to have a client server.. now my IP is let's say 10.0.0.2 and the IP of one of the client is 10.0.0.4. The form i am using is a simple login to see whether my client can login to the system and the database is on the server. Do i have to do a winsock program? i curently have this string connection on the client:
    Code:
    strConn = "driver={SQL Server};server=Test;database=Project;uid=;pwd="
    Do i still need to type in the IP add of the server? if yes where do i put it? and is anything missing from my connection string? thanks very much

  2. #2
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: client server in vb6 and microsoft sql server 2000

    Is the database on the internet or on a internal network file server?

  3. #3

    Thread Starter
    Lively Member
    Join Date
    Feb 2007
    Location
    Manila
    Posts
    85

    Re: client server in vb6 and microsoft sql server 2000

    the database is on an internal network file server.. the client and the server is connected via WiFi

  4. #4
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: client server in vb6 and microsoft sql server 2000

    Then I don't see the need for winsock. You should be able to connect to straight through you connection string using the ado connection object.

  5. #5

    Thread Starter
    Lively Member
    Join Date
    Feb 2007
    Location
    Manila
    Posts
    85

    Re: client server in vb6 and microsoft sql server 2000

    yea but it doesn't work.. i get an error message saying "Login failed for SERVER\guest"

  6. #6
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: client server in vb6 and microsoft sql server 2000

    Are you sure you have the right connection string?

  7. #7
    Super Moderator si_the_geek's Avatar
    Join Date
    Jul 2002
    Location
    Bristol, UK
    Posts
    41,974

    Re: client server in vb6 and microsoft sql server 2000

    You need to have the server name or address in the "server=Test;" part, you can either use the computer name, or the IP address.

    In addition to that, you need to provide some kind of login details - either specify values for uid/pwd if you are using SQL Server logins, or replace them with "Trusted_Connection=Yes;" if you want to use Windows logins.

    Note also that if the client computer is using Windows 2000 or earlier, you should install MDAC on it (link in my signature).

  8. #8

    Thread Starter
    Lively Member
    Join Date
    Feb 2007
    Location
    Manila
    Posts
    85

    Re: client server in vb6 and microsoft sql server 2000

    the Test is the server name.. should i still put the computer name or IP add before the server name?

  9. #9

    Thread Starter
    Lively Member
    Join Date
    Feb 2007
    Location
    Manila
    Posts
    85

    Re: client server in vb6 and microsoft sql server 2000

    i tried it but then i still keep getting the error message "Login failed for SERVER\Guest"

  10. #10
    PowerPoster abhijit's Avatar
    Join Date
    Jun 1999
    Location
    Chit Chat Forum.
    Posts
    3,228

    Re: client server in vb6 and microsoft sql server 2000

    Could you please post your connection string ?
    Everything that has a computer in will fail. Everything in your life, from a watch to a car to, you know, a radio, to an iPhone, it will fail if it has a computer in it. They should kill the people who made those things.- 'Woz'
    save a blobFileStreamDataTable To Text Filemy blog

  11. #11
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: client server in vb6 and microsoft sql server 2000

    And are you using ADO or DAO?

  12. #12
    Super Moderator si_the_geek's Avatar
    Join Date
    Jul 2002
    Location
    Bristol, UK
    Posts
    41,974

    Re: client server in vb6 and microsoft sql server 2000

    Quote Originally Posted by hondaboy24
    the Test is the server name.. should i still put the computer name or IP add before the server name?
    No, just one or the other.

    i still keep getting the error message "Login failed for SERVER\Guest"
    Then the problem is the login details, as I described in my previous post. Either specify uid/pwd, or tell it to use Windows login details (assuming you have enabled Windows logins within SQL Server).

    You also need to make sure that in the Security section of SQL Server, the user has permission to connect to the database.

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