Exemplo n.º 1
0
        private void InitDropDown()
        {
            var actress   = JavDataBaseManager.GetDropDownList("Actress");
            var company   = JavDataBaseManager.GetDropDownList("Company");
            var director  = JavDataBaseManager.GetDropDownList("Director");
            var publisher = JavDataBaseManager.GetDropDownList("Publisher");
            var category  = JavDataBaseManager.GetDropDownList("Category");

            var actressSource = new AutoCompleteStringCollection();

            actressSource.AddRange(actress);

            var companySource = new AutoCompleteStringCollection();

            companySource.AddRange(company);

            var directorSource = new AutoCompleteStringCollection();

            directorSource.AddRange(director);

            var publisherSource = new AutoCompleteStringCollection();

            publisherSource.AddRange(publisher);

            var categorySource = new AutoCompleteStringCollection();

            categorySource.AddRange(category);

            cbActress.AutoCompleteCustomSource = actressSource;
            cbActress.AutoCompleteMode         = AutoCompleteMode.SuggestAppend;
            cbActress.AutoCompleteSource       = AutoCompleteSource.CustomSource;

            cbCompany.AutoCompleteCustomSource = companySource;
            cbCompany.AutoCompleteMode         = AutoCompleteMode.SuggestAppend;
            cbCompany.AutoCompleteSource       = AutoCompleteSource.CustomSource;

            cbDirector.AutoCompleteCustomSource = directorSource;
            cbDirector.AutoCompleteMode         = AutoCompleteMode.SuggestAppend;
            cbDirector.AutoCompleteSource       = AutoCompleteSource.CustomSource;

            cbPublisher.AutoCompleteCustomSource = publisherSource;
            cbPublisher.AutoCompleteMode         = AutoCompleteMode.SuggestAppend;
            cbPublisher.AutoCompleteSource       = AutoCompleteSource.CustomSource;

            cbCategory.AutoCompleteCustomSource = categorySource;
            cbCategory.AutoCompleteMode         = AutoCompleteMode.SuggestAppend;
            cbCategory.AutoCompleteSource       = AutoCompleteSource.CustomSource;

            pageModel      = new PageModel();
            lbCurrent.Text = "0";
            lbTotal.Text   = "0";
        }