VB.NET with SQL SERVER 2005 Database Question

vb.net , sqlserver 2005 United States
  • 12 years ago
    Hi All, I am new to VB.NET and I got a task to develop a database application contains almost 6 to 7 data entry forms alongwith 2 master detail entry forms. I am confuse about how to use SQLConnection object and data adapter thing like on every form loading I should create object like the following Dim ConnectionString As String = "Data Source=AXEPEE;Initial Catalog=master;User ID=sa;Password=admin123" Dim ConnectionObject As New SqlConnection(ConnectionString) Try ConnectionObject.Open() MsgBox("Connection Successfully Varified ! ") ConnectionObject.Close() Catch ex As Exception MsgBox("Can not open connection ! ") End Try and on insert, update & delete button seperate code ...and also want to ask if the above method is professional way to deal with connections..if anyother professional assistance you guys can provide to improve my system performance or how to use this in a professional way I would appreciate.

Post a reply

No one has replied yet! Why not be the first?

Sign in or Join us (it's free).

Contribute

Why not write for us? Or you could submit an event or a user group in your area. Alternatively just tell us what you think!

Our tools

We've got automatic conversion tools to convert C# to VB.NET, VB.NET to C#. Also you can compress javascript and compress css and generate sql connection strings.

“Programs must be written for people to read, and only incidentally for machines to execute.”