PDA

Click to See Complete Forum and Search --> : vb application with client server data access


louisantony
Dec 30th, 2003, 06:16 AM
Hai all,

I created one vb application in my PC with access database as backend.
If it is to be work on Local Area Network (client/server setup that is database
available only on server) what shall i do?

Now i am using DSN LESS connection.
To acheive LAN set up which one is suitable DSN or DSNLESS.

I saw one software in which they provide only the IP of Server while configuring the client,
but client machine automatically idetifies the database of the server using that IP.
How can we do this?

If Database is changed as ORACLE or SQL server what is to be done for the above?

Can anyone help me on this?

Thanks in advance,
Louis

alex_read
Jan 7th, 2004, 07:29 AM
To answer the last bit, if you were using an SQL server backend database, you could use the following code to connect to it which makes use of the server IP address & port number to make the connection:

Dim MyConnectionString As String

MyConnectionString = "Data Source=255.255.255.0,8080; Network Library=DBMSSOCN; Initial Catalog=DataBaseName; UID=UserNameHere; pwd=PasswordHere"

For the first bit, i.e. using an Access database, I would suggest 2 things;

Firstly, if you can, upgrade to the Oracle or SQL Server suggestion as Access doesn't perform well in a client/server multi-user environment & you'll find it easier/less stressful working with a larger database system.

Secondly, go with the DNS / ODBC connection across the network - it's easily setup and more maintainable rather than worrying about changing IP addresses etc. in your code.

louisantony
Feb 1st, 2004, 02:54 AM
Dear Alex

Thank you for your valuable reply

Louis