public T FindControl<T>(string id) where T : Control{ return FindControl<T>(Page, id);} public static T FindControl<T>(Control startingControl, string id) where T : Control{ T found = null; foreach (Control activeControl in startingControl.Controls) { found = activeControl as T; if (found == null) { found = FindControl<T>(activeControl, id); } else if (string.Compare(id, found.ID, true) != 0) { found = null; } if (found != null) { break; } } return found;}