Share via


SPAlternateUrlCollection.Ensure method

Adds an incoming URL to the collection if it does not already exist in the collection.

Namespace:  Microsoft.SharePoint.Administration
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)

Syntax

'Declaration
Public Sub Ensure ( _
    alternateUrl As SPAlternateUrl _
)
'Usage
Dim instance As SPAlternateUrlCollection
Dim alternateUrl As SPAlternateUrl

instance.Ensure(alternateUrl)
public void Ensure(
    SPAlternateUrl alternateUrl
)

Parameters

Remarks

If the specified incoming URL does already exist in the collection, calling the Ensure method does not throw an exception. 

See also

Reference

SPAlternateUrlCollection class

SPAlternateUrlCollection members

Microsoft.SharePoint.Administration namespace