public ContactPanel(Contact[] value) { _count = value.Length; InitializeComponent(); Value = value; }
public ContactParam(Contact[] contacts, CVLookUp cv) : base(null) { _cv = cv; _count = contacts.Length; Value = contacts; Default = contacts; }
public bool AddContactName(int id, string name) { Contact contact; if (!_contactMap.ContainsKey(id)){ contact = new Contact(id){Name = name}; _contactMap.Add(id, contact); return true; } contact = _contactMap[id]; if (contact.Name != null){ return false; } contact.Name = name; return true; }
public bool AddContactEmail(int id, string email) { Contact contact; if (!_contactMap.ContainsKey(id)){ contact = new Contact(id){Email = email}; _contactMap.Add(id, contact); return true; } contact = _contactMap[id]; if (contact.Email != null){ return false; } contact.Email = email; return true; }
public bool AddContactAffiliation(int id, string affiliation) { Contact contact; if (!_contactMap.ContainsKey(id)){ contact = new Contact(id){Affiliation = affiliation}; _contactMap.Add(id, contact); return true; } contact = _contactMap[id]; if (contact.Affiliation != null){ return false; } contact.Affiliation = affiliation; return true; }
public override void Clear() { Value = new Contact[_count]; }