I have created a databse using sql database "TestingSQL" using microsoft management studio 2012 and created a simple vb application as a tryout. It works well in my pc and i would be able to access remotely as well. But the problem is, it is only works with my windows credentials and other users are not able to connect via the application eventhough we belong to the same domain. I'm new to sql and could anybody tell me the problem. thanks In advance.
Sql database i've tried both sa and windows authentication but failed. the error i got was
<<<can't open database "TestingSQL" requested by the login. The login failed.
Login failed for user " domain name\user name >>>>>>
below is my coding.
Public Class Form1
Private con1 As New SqlConnection("Data Source=ComputerName;Initial Catalog=TestingSQL;Integrated Security=True") Private da As New SqlDataAdapter("SELECT * From User5600", con1) Private ds As New DataSet Private cd As New SqlCommandBuilder Dim sqlinsert As String Dim cmd As New SqlCommand Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click da.Fill(ds, "User5600") DGV.DataSource = ds.Tables("User5600") End Sub Private Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click sqlinsert = "INSERT INTO User5600 (InstrumentSN, BayNo)" & "VALUES(@InstrumentSN, @BayNo)" cmd = New SqlCommand(sqlinsert, con1) cmd.Parameters.Add("@InstrumentSN", SqlDbType.Text).Value = txtInstrumentNo.Text cmd.Parameters.Add("@BayNo", SqlDbType.Text).Value = txtBayNo.Text con1.Open() cmd.ExecuteNonQuery() con1.Close() MsgBox("updated") End Sub