Control::ControlCollection::Find Method (String^, Boolean)
.NET Framework (current version)
Searches for controls by their Name property and builds an array of all the controls that match.
Assembly: System.Windows.Forms (in System.Windows.Forms.dll)
Parameters
- key
-
Type:
System::String^
The key to locate in the Control::ControlCollection.
- searchAllChildren
-
Type:
System::Boolean
true to search all child controls; otherwise, false.
Return Value
Type: array<System.Windows.Forms::Control^>^An array of type Control containing the matching controls.
| Exception | Condition |
|---|---|
| ArgumentException | The key parameter is null or the empty string (""). |
.NET Framework
Available since 2.0
Available since 2.0
Show: