Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

SPWebServiceCollection class

Represents a collection of SPWebService objects.

Namespace:  Microsoft.SharePoint.Administration
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)
[SharePointPermissionAttribute(SecurityAction.LinkDemand, ObjectModel = true)]
public sealed class SPWebServiceCollection : SPPersistedChildCollection<SPWebService>

Use the SPWebServiceCollection constructor to return the collection of Web services within the server farm. To create a Web service, use the SPWebService to initialize the Web service object, and use the Add method to add the new object to the collection of Web services within the server farm.

Use an indexer to return a single Web service from the collection. For example, if the collection is assigned to a variable named myWebServices, use myWebServices[index] in C#, or myWebServices(index) in Visual Basic, where index is either the name or the GUID identifying the Web service.

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.