Beispiel #1
0
 public Contact(DataRow customer, DataRow person)
 {
     this.customer = customer;
     this.person = person;
     if(!(customer["Photo"] is DBNull)) {
         photo = ByteImageConverter.FromByteArray((byte[])customer["Photo"]);
         hasPhoto = true;
     } else photo = global::DevExpress.MailClient.Win.Properties.Resources.Unknown_user;
     name = new FullName(string.Format("{0}", person["FirstName"]), string.Format("{0}", customer["MiddleName"]), string.Format("{0}", person["LastName"]));
     email = string.Format("{0}", customer["Email"]).Replace("dxvideorent.com", "dxmail.net");
     gender = (ContactGender)person["Gender"];
     birthDate = (DateTime?)person["BirthDate"];
     phone = string.Format("{0}", customer["Phone"]);
     address = new Address(string.Format("{0}", customer["Address"]));
 }
Beispiel #2
0
 public void Assign(FullName name)
 {
     this.title = name.Title;
     this.first = name.FirstName;
     this.middle = name.MiddleName;
     this.last = name.LastName;
 }
Beispiel #3
0
 public Contact(Contact contact)
 {
     name = new FullName();
     address = new Address();
     this.Assign(contact);
 }
Beispiel #4
0
 public Contact()
 {
     name = new FullName(Properties.Resources.NewFirstName, string.Empty, Properties.Resources.NewLastName);
     address = new Address();
 }
Beispiel #5
0
 public Contact() {
     name = new FullName(DevExpress.ProductsDemo.Win.Properties.Resources.NewFirstName, string.Empty, DevExpress.ProductsDemo.Win.Properties.Resources.NewLastName);
     address = new Address();
 }
Beispiel #6
0
 public Contact(Contact contact)
 {
     _name    = new FullName();
     _address = new Address();
     this.Assign(contact);
 }
Beispiel #7
0
 public Contact()
 {
     _name    = new FullName(DevExpress.ProductsDemo.Win.Properties.Resources.NewFirstName, string.Empty, DevExpress.ProductsDemo.Win.Properties.Resources.NewLastName);
     _address = new Address();
 }