Compartir a través de


Database Constructor

Initializes a new instance of the Database class.

Espacio de nombres:  Microsoft.SqlServer.Management.Smo
Ensamblado:  Microsoft.SqlServer.Smo (en Microsoft.SqlServer.Smo.dll)

Sintaxis

'Declaración
Public Sub New
'Uso

Dim instance As New Database()
public Database()
public:
Database()
new : unit -> Database
public function Database()

Notas

El constructor predeterminado inicializa los campos con sus valores predeterminados.

You will have to specify which server is the parent of the database before you can create a database.

Ejemplos

Dim srv As Server
srv = New Server()

'Create a new database by using the default constructor.
Dim db As Database
db = New Database
db.Name = "New_Database"
db.Parent = srv
db.Create()