Exemplo n.º 1
0
        private void FillAppendixe2()
        {
            string[] orderBy = new string[] { "Appendix2Code" };
            ProductAppendix2Ex.LoadCombo(ref cboAppendix2, "Appendix2Code", false, true, "", "", orderBy);

            /**
             * cboAppendix2.Items.Clear();
             *
             * string[] orderBy = new string[] { "Appendix2Code" };
             * ProductAppendix2Collection oA2List = ProductAppendix2.LoadCollection(orderBy, true);
             * oA2List.Add(new ProductAppendix2());
             * cboAppendix2.DataSource = oA2List;
             * cboAppendix2.DisplayMember = "Appendix2Code";
             * cboAppendix2.ValueMember = "Appendix2Id";
             */
            //cboAppendix2.SelectedIndex = cboAppendix2.Items.Count - 1;
        }
Exemplo n.º 2
0
        private void FillComboBox()
        {
            string textField = this.AppendixType.Trim() + "Code";

            switch (this.AppendixType.Trim().ToUpper())
            {
            case "APPENDIX1":
                ProductAppendix1Ex.LoadCombo(ref cmbFrom, textField, false);
                ProductAppendix1Ex.LoadCombo(ref cmbTo, textField, false);
                break;

            case "APPENDIX2":
                ProductAppendix2Ex.LoadCombo(ref cmbFrom, textField, false);
                ProductAppendix2Ex.LoadCombo(ref cmbTo, textField, false);
                break;

            case "APPENDIX3":
                ProductAppendix3Ex.LoadCombo(ref cmbFrom, textField, false);
                ProductAppendix3Ex.LoadCombo(ref cmbTo, textField, false);
                break;
            }

            cmbTo.SelectedIndex = cmbTo.Items.Count - 1;
        }