asp.net.ph

OleDbConnection Constructor

System.Data.OleDb Namespace   OleDbConnection Class


Initializes a new instance of the OleDbConnection class.

Overload List

1. Initializes a new instance of the OleDbConnection class.

2. Initializes a new instance of the OleDbConnection class with the specified ConnectionString.


Example

The following example initializes and opens an OleDbConnection with the given connection string.

NOTE: This example uses one of the overloaded versions of the OleDbConnection constructor. For other examples that may be available, see the individual overload topics.

string connString = "Provider=Microsoft.ACE.OLEDB.12.0; Data Source=myData.mdb"
OleDbConnection myConn = new OleDbConnection ( connString );
myConn.Open ( );
  C# VB

See Also

OleDbConnection Members   ConnectionString   Connecting to a Database Skip Navigation Links




Previous page Back to top Next page

Check out related books at Amazon

© 2025 Reynald Nuñez and asp.net.ph. All rights reserved.

If you have any question, comment or suggestion
about this site, please send us a note