DataFormWebPart.FindControlInNamingContainerStack method

Finds the specified control in a stack of NamingContainer objects.

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

Syntax

'Declaration
Public Shared Function FindControlInNamingContainerStack ( _
    control As Control, _
    controlId As String _
) As Control
'Usage
Dim control As Control
Dim controlId As String
Dim returnValue As Control

returnValue = DataFormWebPart.FindControlInNamingContainerStack(control, _
    controlId)
public static Control FindControlInNamingContainerStack(
    Control control,
    string controlId
)

Parameters

Return value

Type: System.Web.UI.Control

Remarks

Walks up the stack of NamingContainer objects starting at control to find a control that has the ID controlId. If control is itself an INamingContainer object, the search begins with the control; otherwise, the search begins with control.NamingContainer.

See also

Reference

DataFormWebPart class

DataFormWebPart members

Microsoft.SharePoint.WebPartPages namespace