M
Mesut
Hi Colleagues,
I hope someone can help me what I'm doing wrong...
I filled in my connection string in my application see below and I
would like to open my Connection to my SQL database file. I try to open
my connection and I get the next error message. I tried to change some
values in my connection string but I still get the same error.
Everything is on my standalone laptop, I use Windows XP (Stand Alone)
and I use a simple userid to login: "demir" (no password). I have
installed VB.NET Express Edition and SQL 2005 Express Edition (both
packages are free downloadable from Microsoft site)
Has it to do because of FREE SQL? limited SQL? I can't imagine it....
Can someone please advice what is wrong in my SqlConnection string or
somewhere else.....
This is my code in VB.NET 2005 Express Edition (Visual Studio)
Imports System.Data.Sqlclient
===> this gives an error
con.ConnectionString = "data source=LOCALHOST;initial
catalog=C:\Documents and Settings\Mesut\My
Documents\myDatabaseFile;password="""";persist security info=True;user
id=demir;workstation id=DEMIR;Packet Size=4096"
===> and this also gives an error...
con.ConnectionString = "data source=LOCALHOST;initial
catalog=myDatabaseFile;password="""";persist security info=True;user
id=demir;workstation id=;Packet Size=4096"
con.Open()
This is the errror message when I try to open the connection...
-->
An error has occurred while establishing a connection to the server.
When connecting to SQL Server 2005, this failure may be caused by the
fact that under the default settings SQL Server does not allow remote
connections. (provider: Named Pipes Provider, error:40 - Could not
open a connection to SQL Server)
I hope someone can help me what I'm doing wrong...
I filled in my connection string in my application see below and I
would like to open my Connection to my SQL database file. I try to open
my connection and I get the next error message. I tried to change some
values in my connection string but I still get the same error.
Everything is on my standalone laptop, I use Windows XP (Stand Alone)
and I use a simple userid to login: "demir" (no password). I have
installed VB.NET Express Edition and SQL 2005 Express Edition (both
packages are free downloadable from Microsoft site)
Has it to do because of FREE SQL? limited SQL? I can't imagine it....
Can someone please advice what is wrong in my SqlConnection string or
somewhere else.....
This is my code in VB.NET 2005 Express Edition (Visual Studio)
Imports System.Data.Sqlclient
===> this gives an error
con.ConnectionString = "data source=LOCALHOST;initial
catalog=C:\Documents and Settings\Mesut\My
Documents\myDatabaseFile;password="""";persist security info=True;user
id=demir;workstation id=DEMIR;Packet Size=4096"
===> and this also gives an error...
con.ConnectionString = "data source=LOCALHOST;initial
catalog=myDatabaseFile;password="""";persist security info=True;user
id=demir;workstation id=;Packet Size=4096"
con.Open()
This is the errror message when I try to open the connection...
-->
An error has occurred while establishing a connection to the server.
When connecting to SQL Server 2005, this failure may be caused by the
fact that under the default settings SQL Server does not allow remote
connections. (provider: Named Pipes Provider, error:40 - Could not
open a connection to SQL Server)