VB.Net Tutorial/Database ADO.net/SqlConnection
Версия от 16:40, 26 мая 2010; (обсуждение)
Connection string for SqlConnection
Module Module1
Dim sConnection As String = "Password=password;Persist Security Info=True;User ID=sa;Initial Catalog=CD;Data Source=(local)"
Sub Main()
Dim objConn As New System.Data.SqlClient.SqlConnection(sConnection)
Try
objConn.Open()
Catch myException As System.Exception
Console.WriteLine(myException.Message)
End Try
Console.ReadLine()
End Sub
End Module