Exemple #1
0
        void SaveMessageDB_HT_ThongTinNguoiQuanHeBN(OpenPop.Mime.Message message)
        {
            try
            {
                string mes = message.FindFirstPlainTextVersion().GetBodyAsText();

                XDocument xDoc = XDocument.Parse(mes);
                HT_ThongTinNguoiQuanHeBN nqh = new HT_ThongTinNguoiQuanHeBN(xDoc);
                if (dbht.GetVoBNByID(nqh.Id) == null)
                {
                    dbht.AddVoBN(nqh.MaBN, nqh);
                }
                else
                {
                    dbht.EditVoBN(nqh.Id, nqh);
                }

                SaveFile(message);
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }