Saturday, December 08, 2012 9:14 PM
Hello there, I have created a windows form using ADO.NET inside of it to write/update/delete from a table in my SQL server.
Now my porject is working fine with no problems with I use it on my PC where I created my SQL database table, but what I want not is to install this windows form on another machine which is connected to the same network at my work, but I dont know how can I change the connection string so that the other machine could access it from my machine through our work network.
Here is my connection string right now which is working fine locally:
Dim cn As New SqlConnection cn.ConnectionString = "Data Source=.;Initial Catalog=master;Integrated Security=True"
Now to access my pc at work I have to enter a user namer and password for windows to be able to be logged in, lets say my user name is operator and pass is 123, what changes do I have to do to this code to make it work? Note that I am using Visual Studio 2010 and VB.NET, thanx in advance.
Saturday, December 08, 2012 10:16 PM
On this page you can read about all properties you can set in a connection string:
I post this link rather than just giving you the answer, as having knowledge about what you can put into a connection string is essential for all data-access programming.
Erland Sommarskog, SQL Server MVP, firstname.lastname@example.org