I
Ian
Hi all
I'm coming to ASP/SQL Server after 15 years in Delphiland. Like all good
newbies I'm trying to work my way through samples and RTFMing like mad. But
I'm having a major problem getting even the most basic thing off the ground.
I'm trying to run a sample from the M$ library that connects to the
Northwind DB. It's about the most basic thing there is, and I've been
struggling with it for over a day. Time for me to find a kind guru.
Function RunQuery(ByVal QueryString As String) As DataSet
' Declare the connection string. This example uses Microsoft SQL Server
' and connects to the Northwind sample database.
Dim ConnectionString As String = "blah, blah"
Dim DBConnection As SqlConnection = New SqlConnection(ConnectionString)
For the ConnectionString I have tried every possible combination of
'server', 'data source', 'database', 'security', etc, etc that I can think
of or have found in examples of on the web. Even the ones at
connectionstring don't get me to connect. All I get when I go through the
connect stage is 'Invalid operation. The connection is closed' in the
DBConnection properties. I am using SQL Server Express and I've included the
\sqlexpress after server name, long names for databases and servers, and I
am now getting a tad frustrated. Heck, this is for newbies like me and I
can't even get it to work out of the box!
Google has retired with a
headache I've spent that long poking around trying to find an answer.
Anyway, any free clues will be very much appreciated. I'm *sure* I can get
to enjoy this thing, once I get in the front door.
TIA
Ian
I'm coming to ASP/SQL Server after 15 years in Delphiland. Like all good
newbies I'm trying to work my way through samples and RTFMing like mad. But
I'm having a major problem getting even the most basic thing off the ground.
I'm trying to run a sample from the M$ library that connects to the
Northwind DB. It's about the most basic thing there is, and I've been
struggling with it for over a day. Time for me to find a kind guru.

Function RunQuery(ByVal QueryString As String) As DataSet
' Declare the connection string. This example uses Microsoft SQL Server
' and connects to the Northwind sample database.
Dim ConnectionString As String = "blah, blah"
Dim DBConnection As SqlConnection = New SqlConnection(ConnectionString)
For the ConnectionString I have tried every possible combination of
'server', 'data source', 'database', 'security', etc, etc that I can think
of or have found in examples of on the web. Even the ones at
connectionstring don't get me to connect. All I get when I go through the
connect stage is 'Invalid operation. The connection is closed' in the
DBConnection properties. I am using SQL Server Express and I've included the
\sqlexpress after server name, long names for databases and servers, and I
am now getting a tad frustrated. Heck, this is for newbies like me and I
can't even get it to work out of the box!

headache I've spent that long poking around trying to find an answer.
Anyway, any free clues will be very much appreciated. I'm *sure* I can get
to enjoy this thing, once I get in the front door.

TIA
Ian