共用方式為


Add 方法 (DatabaseEventSet, DatabaseEvent)

Returns a set of database events after adding a new database event to the specified event set.

命名空間:  Microsoft.SqlServer.Management.Smo
組件:  Microsoft.SqlServer.Smo (在 Microsoft.SqlServer.Smo.dll 中)

語法

'宣告
Public Shared Function Add ( _
    eventSet As DatabaseEventSet, _
    anEvent As DatabaseEvent _
) As DatabaseEventSet
'用途
Dim eventSet As DatabaseEventSet
Dim anEvent As DatabaseEvent
Dim returnValue As DatabaseEventSet

returnValue = DatabaseEventSet.Add(eventSet, _
    anEvent)
public static DatabaseEventSet Add(
    DatabaseEventSet eventSet,
    DatabaseEvent anEvent
)
public:
static DatabaseEventSet^ Add(
    DatabaseEventSet^ eventSet, 
    DatabaseEvent^ anEvent
)
static member Add : 
        eventSet:DatabaseEventSet * 
        anEvent:DatabaseEvent -> DatabaseEventSet 
public static function Add(
    eventSet : DatabaseEventSet, 
    anEvent : DatabaseEvent
) : DatabaseEventSet

參數

傳回值

型別:Microsoft.SqlServer.Management.Smo. . :: . .DatabaseEventSet
A DatabaseEventSet object that contains the new DatabaseEvent object.