I have finished a program using sql server and visual studio using c# language .
I want to put the database on pc and the program that connected to that database on other PCs
I’m using this connection string in App.config :
<connectionStrings>
<add name="MWEConnectionString" connectionString ="integrated security=yes;initial catalog=MWDB;data source=.\sqlexpress"/>
</connectionStrings>
Should I change server name by pc external ip address?
and according to sql server Should I use windows authentication or what?
I don’t know how to do it.
You should access the server by it’s address by using Sql Server authentication.
Your connection string should look something like this:
(this is just an example, your settings will probably be different).
Another example:
for accessing the server by name.
You can generate a connection string for your application from Visual Studio. From
Database Explorer -> Connect to Database