If you don't actually perform a SQL Command in between the Open and the
Close, you would never know.
ADO will not actually attempt to acquire a connection object until you need
one. From the code you posted below, you don't need one.
Put in a command object to do something trivial. Then your connection
string will be validated.
--- Nick
"Job Lot" <Jo****@discussions.microsoft.com> wrote in message
news:A9**********************************@microsof t.com...
I am connecting to my SQL database using following connection string
Dim strSQL = "Persist Security Info=False;Integrated
Security=False;database=myDA;server=myServerNane;U ser ID=;Password="
Dim conn As New SqlConnection(strSQL)
conn.Open()
conn.Close()
The above code works fine, even if User ID and password are blank? How is
it possible?