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

                XDocument    xDoc = XDocument.Parse(mes);
                HT_LuuTruMau ltm  = new HT_LuuTruMau(xDoc);
                if (dbht.GetLuuTruMauByID(ltm.Id) == null)
                {
                    dbht.AddLuuTruMau(ltm);
                }
                else
                {
                    dbht.EditLuuTruMau(ltm.Id, ltm);
                }

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