SubMenuStyleCollection.Contains Method (SubMenuStyle)


The .NET API Reference documentation has a new home. Visit the .NET API Browser on to see the new experience.

Determines whether a SubMenuStyleCollection collection contains a specific SubMenuStyle instance.

Namespace:   System.Web.UI.WebControls
Assembly:  System.Web (in System.Web.dll)

Public Function Contains (
	style As SubMenuStyle
) As Boolean


Type: System.Web.UI.WebControls.SubMenuStyle

The SubMenuStyle instance to locate in the SubMenuStyleCollection collection.

Return Value

Type: System.Boolean

true if the SubMenuStyle instance is found in the SubMenuStyleCollection collection; otherwise, false. If null is passed as the style parameter, false is returned.

The OnValidate method is called to validate the style parameter before the SubMenuStyleCollection collection is checked.

.NET Framework
Available since 2.0
Return to top