Click here to Skip to main content
15,891,136 members
Articles / Programming Languages / C#

Outlook Type Address Book in C#, LINQ, XML with Menu and ToolBar

Rate me:
Please Sign up or sign in to vote.
4.70/5 (8 votes)
28 Aug 2009CPOL4 min read 41K   1.6K   31  
Outlook type Address Book in C#, LINQ, XML with Menu and ToolBar
using System;
using System.Collections.Generic;
using System.Text;

namespace AddressBook
{
    public class Contacts
    {
        #region Fields
        //Primary Key
        private string _email;


        private int _contactID;
        private string _fName;
        private string _lName;        
        private string _address1;
        private string _address2;
        private string _city;
        private string _state;
        private string _country;
        private string _zip;
        private string _phone1;
        private string _phone2;

        #endregion

        public Contacts()
        {
        }

        public Contacts(string fName, string lName, string eMail, string address1, string address2,
            string city, string state, string country, string zip, string phone1, string phone2)
        {
            _fName = fName;
            _lName = lName;
            _email = eMail;
            _address1 = address1;
            _address2 = address2;
            _city = city;
            _state = state;
            _zip = zip;
            _country = country;
            _phone1 = phone1;
            _phone2 = phone2;
            _contactID = 1;
        }


        #region Properties
        public virtual int ContactID
        {
            get { return _contactID; }
            set { _contactID = value; }
        }
        public virtual string FName
        {
            get { return _fName; }
            set { _fName = value; }
        }
        public virtual string LName
        {
            get { return _lName; }
            set { _lName = value; }
        }
        public virtual string Email
        {
            get { return _email; }
            set { _email = value; }
        }
        public virtual string Address1
        {
            get { return _address1; }
            set { _address1 = value; }
        }
        public virtual string Address2
        {
            get { return _address2; }
            set { _address2 = value; }
        }
        public virtual string City
        {
            get { return _city; }
            set { _city = value; }
        }
        public virtual string State
        {
            get { return _state; }
            set { _state = value; }
        }
        public virtual string Country
        {
            get { return _country; }
            set { _country = value; }
        }
        public virtual string Zip
        {
            get { return _zip; }
            set { _zip = value; }
        }
        public virtual string Phone1
        {
            get { return _phone1; }
            set { _phone1 = value; }
        }
        public virtual string Phone2
        {
            get { return _phone2; }
            set { _phone2 = value; }
        }        
        #endregion
    }
}

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Software Developer Shell Oil
United States United States
I am working as a Senior Software Developer with Shell Oil,Houston Texas USA.

Comments and Discussions