Click here to Skip to main content
15,913,301 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more:
I want to create a desktop application using C#.net. but i want to use it as multiuser.ie, i want to put the database in a local sever and want to run the application in several computers in the same network.

: Database is in a central system and application in several computers,and when user
enter values to DB via any system will get updated in the DB in Central system.


I dnt know its possible or not,if possible please help me
Posted
Comments
Sergey Alexandrovich Kryukov 23-Jun-11 0:19am    
What kind of help? What you ask is what is usually done, so it's not clear what can you do and what not. You need to explain what's the problem is.
--SA
kishore Rajendran 23-Jun-11 0:26am    
need the connection string to connect to DB

Without knowing your Database engine I would suggest that you start with www.connectionstrings.com[^]
 
Share this answer
 
Yes, It is possible.

If your db server (or Machine where the SQL Server is installed) is in network then build a connection string in your application with the name of DB Server with require credentials. It will work.
 
Share this answer
 
When you create a connection to the DB you are likely going to use a connection string. This will be stored in you app.config file. It doesn't matter where this DB is, as long as the IP address it is sitting on is available to all computers from which you wish to access it.

There is a side note here worth mentioning: if you are storing username/password in the connection string you're going to want to look at encrypting your credentials[^].

Cheers.
 
Share this answer
 
Well all the solution given above looks good (although i have not tried them).But i would recommend you to use client server architecture. What basically you need to do is have an application which will run on the server where your SQL server is installed (this will be called server) and other application which will run on other machine (this will be called client). Now the client will always make request to server and (it will have no direct link with your database) server will process the request and send the output to client. For example let assume you need to save some data into database. The client application will get the data from user and send it to server and server will save the data into database.
 
Share this answer
 
I would recommend that you create a Windows Communication Service (WCF) on your server, which does all the updates to the database. Then you can create your windows/web application that uses this WCF service to fetch, insert and update your data.

Hope this helps
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900