Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 10.0.1 » UltraLite - .NET Programming » UltraLite .NET 2.0 API Reference » ULDatabaseManager class

CreateDatabase method Next Page

DropDatabase method


Deletes the specified database.

You cannot drop a database that has open connections.

Syntax

Visual Basic

Public Sub DropDatabase( _
ByVal connString As String _
)

C#

public void DropDatabase(
string connString
);

Parameters
Example

The following code creates the database \UltraLite\MyDatabase.udb on a Windows CE device then opens a connection to it.

' Visual Basic
Dim connParms As ULConnectionParms = New ULConnectionParms
connParms.DatabaseOnCE = "\UltraLite\MyDatabase.udb"
ULConnection.DatabaseManager.DropDatabase( _
    connParms.ToString() _
  )


// C#
ULConnectionParms connParms = new ULConnectionParms();
connParms.DatabaseOnCE = @"\UltraLite\MyDatabase.udb";
ULConnection.DatabaseManager.DropDatabase(
    connParms.ToString()
  );
ULConnection conn = new ULConnection( openParms.ToString() );
conn.Open();
See also