Knight Data Access Layer
Database Exists VB.NET
Basic Tasks VB.NET > Database Commands > Database Exists VB.NET

Check to see if a database exists.  For file based databases, pass in the full path for the file.  For server based databases, pass in the name of the database.

 

'Get the current instance of the helper

Dim db As IDataHelper = DataHelper.SessionFactory()

 

Dim exists As Boolean = db.DatabaseExists("InvoiceDatabase")