Ejemplo n.º 1
0
        private void PopulateSearch()
        {
            try
            {
                cmbSearch.DataSource    = med.SearchValues();
                cmbSearch.ValueMember   = "Value";
                cmbSearch.DisplayMember = "Display";

                //populate cmbactive
                Dictionary <int, string> activeDictionary = new Dictionary <int, string>();
                activeDictionary.Add(1, "True");
                activeDictionary.Add(0, "False");

                cmbActive.DataSource    = new BindingSource(activeDictionary, null);
                cmbActive.DisplayMember = "Value";
                cmbActive.ValueMember   = "Key";
            }
            catch (Exception ex)
            {
                CommonLogger.Info(ex.ToString());
            }
        }