Smart FindControl implementation

Find a control recursively in C#, By PsychoCoder

public Control FindControlRecursive(Control container, string name)
{
if (container.ID == name)
return container;

foreach (Control ctrl in container.Controls)
{
Control foundCtrl = FindControlRecursive(ctrl, name);
if (foundCtrl != null)
return foundCtrl;
}
return null;
}