다음을 통해 공유


SPPersistedChildCollection<T>.Add Method

Adds an object to the collection.

Namespace:  Microsoft.SharePoint.Administration
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Available in Sandboxed Solutions: No

Syntax

'Declaration
Public Overridable Function Add ( _
    newObj As T _
) As T
'Usage
Dim instance As SPPersistedChildCollection
Dim newObj As T
Dim returnValue As T

returnValue = instance.Add(newObj)
public virtual T Add(
    T newObj
)

Parameters

  • newObj
    Type: T

    The object to add to the collection.

Return Value

Type: T
The object that was added.

Exceptions

Exception Condition
ArgumentException

The object already exists in the collection.

See Also

Reference

SPPersistedChildCollection<T> Class

SPPersistedChildCollection<T> Members

Microsoft.SharePoint.Administration Namespace