windows phone 7 - How to save multiple contact? -


i developing windows phone app require save multiple contact. have store contact in list. want save contact 1 one.

here code

  var data = q in document.descendants("contact")                    select new contactlist                    {                        displayname = q.element("name").value,                        email = !string.isnullorempty(q.element("email").value) ? q.element("email").value : " ",                        address = !string.isnullorempty(q.element("address").value) ? q.element("address").value : " ",                        //phonenumber = m.phonenumbers.firstordefault()                        phonenumber = !string.isnullorempty(q.element("phonenumber").value) ? q.element("phonenumber").value : " "                    };          contactlist con = null;                     savecontactlist = new list<contactlist>();          foreach (var c in data)         {             con = new contactlist();             con.displayname = c.displayname;             con.address = c.address;             con.email = c.email;             con.phonenumber = c.phonenumber;                             savecontactlist.add(con);                  } 

here have store contact in savecontactlist. want save these contact. how can save these contact ?

if trying save them windows phone phonebook - there no way save contacts @ time.

you can save them 1 1, may use foreach

sample save contact:

var phonecalltask = new phonecalltask         {             displayname = contactname.text,             phonenumber = phonetext.text         };         phonecalltask.show(); 

Comments

Popular posts from this blog

basic authentication with http post params android -

vb.net - Virtual Keyboard commands -

css - Firefox for ubuntu renders wrong colors -