////////////////////////////////////////////////// меню "Поиск" private void ShowSearchForm(SearchFormArgs args) { IFormBuilder builder = new SearchFormBuilder(args, this); Form searchForm = FormDirector.CreateForm(builder); searchForm.Show(); }
public SearchForm(SearchFormArgs sfa) { InitializeComponent(); dateTimePickerYear.Format = DateTimePickerFormat.Custom; dateTimePickerYear.CustomFormat = "yyyy"; dateTimePickerYear.ShowUpDown = true; if (sfa.type) { checkBoxType.CheckState = CheckState.Checked; } if (sfa.year) { checkBoxYear.CheckState = CheckState.Checked; } if (sfa.district) { checkBoxDistrict.CheckState = CheckState.Checked; } if (sfa.city) { checkBoxCity.CheckState = CheckState.Checked; } }
public SearchFormBuilder(SearchFormArgs sfa, MainForm parent) { _parent = parent; currentForm = new SearchForm(sfa); }