using System; using System.Collections.Generic; using System.Text; namespace FPER { /** * cboUse_Flag.Items.Clear(); * ArrayList ary = new ArrayList(); * ary.Add(new cboitem("Y", "»ç¿ëÇÔ")); * ary.Add(new cboitem("N", "»ç¿ë¾ÈÇÔ")); * * cboUse_Flag.DataSource = ary; * cboUse_Flag.DisplayMember = "text"; * cboUse_Flag.ValueMember = "value"; * * * * CType(cboYear.SelectedItem, cmbValue).ToString(); * * ***/ public class cboitem { private object cboValue = null; private object cboText = null; public cboitem(object val, object txt) { //base(); this.cboValue = val; this.cboText = txt; } public object ValueObject { get { return this.cboValue; } } public String value { get { return this.cboValue.ToString(); } } public String text { get { return this.cboText.ToString(); } } public override string ToString() { if (this.cboValue == null) return ""; else return this.cboValue.ToString(); //return ""; } } }