public ControlElement(FieldElement field) { this.field = field; _getValue = new AutoControl.GetControlValue(this.GetValue); this.field.BindGetValue(_getValue); ToBuild(); }
public ControlElement GetControlElementByInfo(string tbName, string fieldName) { int conLen = this.controls.Count; for (int i = 0; i < conLen; i++) { if (this.controls[i].Field.FieldName == fieldName && this.controls[i].Field.FieldTable == tbName) { return(this.controls[i]); } } int len = tabs.Count; FieldElement field = null; for (int i = 0; i < len; i++) { if (tabs[i].tableName == tbName) { field = tabs[i].GetFieldElement(fieldName); } } if (field != null) { if (field._Type == ControlType.Text) { charText _charText = new charText(field); return(_charText); } else if (field._Type == ControlType.ComboBox) { comboBox _box = new comboBox(field); return(_box); } else if (field._Type == ControlType.TimeBox) { timeBox _timebox = new timeBox(field); return(_timebox); } else if (field._Type == ControlType.NumericEdit) { NumericEdit _NumericEdit = new NumericEdit(field); return(_NumericEdit); } } return(null); }
public timeBox(FieldElement field) : base(field) { }
public comboBox(FieldElement field) : base(field) { }
public NumericEdit(FieldElement field) : base(field) { }
public charText(FieldElement field) : base(field) { }