internal static void FormLoad(Form form, string lblText) { List <Control> allControls = ExtensionMethods.GetAllControls(form); allControls.ForEach(k => { if (k is ComboBox) { ((ComboBox)k).FlatStyle = FlatStyle.Flat; } }); allControls.ForEach(k => { if (k is TextBox) { ((TextBox)k).CharacterCasing = CharacterCasing.Upper; } }); // Exclude.GetExcludedControls( allControls = allControls.Where(x => !Exclude.GetExcludedControls().Where(p => p.Name == x.Name).Any()).ToList(); //allControls.ForEach(k =>{ if (k.Name != "lblSearch" && k.Name != "txtSearch" && k.Name != "lblPersonRouteType") { k.Font = new System.Drawing.Font(ExtensionMethods.FontFamily, ExtensionMethods.FontSize); } }); allControls.ForEach(k => { k.Font = new System.Drawing.Font(ExtensionMethods.FontFamily, ExtensionMethods.FontSize); }); LoadPanel(form, lblText); }