I am trying to connect to a SQL DB and I have owner access, but I am unable to connect.
Here is my connectionstring:
Dim connectionString As String = _
"Data Source=db server name" & _
"Initial Catalog=name;Integrated Security=true"
Dim theDatabase As New SqlClient.SqlConnection(connectionString)
theDatabase.Open()
and the error I get is:
(Priovider: Named Pipes Provider, Error: 40 - could not open a connection to SQL server)
the details state that under default settings SQL server does not allow remote connection.
Also:
I don't know if this is any help to you all out there, but I ran a debug and found this:
Error for : theDatabase.Open()
EXECUTE permission denied on object 'sp_sdidebug', database 'master', owner 'dbo'
and
Here is the start of my code (connection wise)...I'm new to this type of
VB application:
Imports System.Data.SqlClient
Imports System.Data
Imports System.Data.Sql
Imports System.Data.SqlClient.SqlException
Public Class Form1
Private Sub adddefectbutton_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles adddefectbutton.Click
'When Clicked the Data will be insterted into the database.
'-------Connect to the Database
Dim connectionString As String = "Data Source=san-sql.corp.advertising.com;Initial Catalog=Ontimetesting;Integrated Security=true;"
Dim theDatabase As New SqlClient.SqlConnection(connectionString)
theDatabase.Open()
I hope all the information I provided helps: I need help on this, please.
I've tried everything I can think of...any ideas?
Newbie