Here is the link: http://asp.dotnetheaven.com/howto/doc/adoplus/DatabaseTrans.aspx.  It has examples in C#, VB, and C++.

  1. Select the My Project file in Solution Explorer  (Figure 1).
  2. Select the Application category and change the Startup form from a list (Figure 2). 

myproject.JPG

<Figure 1>

startupform.JPG

<Figure 2>

Suppose that your computer name is TAG302757  and  you create a database TESTDB in your local SQLExpress server. Then the connection string of the database is:

“Data Source=TAG302757\SQLEXPRESS;Initial Catalog=TESTDB;Integrated Security=True”

Note that there is a space  between the words Initial and Catalog; and the the connection string must be in the same line of your VB program.

If you cannot see the Data Sources window, select the menu Data>>Show Data Sources. If you cannot see the  Add New Data Sources icon, right-click the Data Sources window to use the popup menu.

Miscosoft Visual Studio 2005 comes with a personal SQL Server (or SQLEXPRESS).  You may get an error message when trying to add a connection to the SQLEXPRESS server for your project. The ”Add Connection” dialog usually shows your computer name in the “server name” field. You have to add a back slash and the “SQLEXPRESS” string for a sucessful connection (See the figure below).

 sqlexpress.JPG