public List <KeyValuePair <string, string> > GetObjectAttributeTypes() { List <KeyValuePair <string, string> > items = new List <KeyValuePair <string, string> >(); using (SqlDataReader reader = ObjectAttribute.GetAllObjectAttributeTypes()) { while (reader.Read()) { items.Add(new KeyValuePair <string, string>(Convert.ToString(reader["Name"]), Convert.ToString(reader["ObjectAttributeTypeID"]))); } } return(items); }