示例#1
0
        private void ConstruiesteRanduriDGV()
        {
            this.dgvEmail.IncepeContructieRanduri();

            var listaEmailuriExtrase = BEmailuriExtrase.GetListByParamIdEmail(this.lEmail.Id, CDL.iStomaLab.CDefinitiiComune.EnumStare.Activa, null);

            foreach (var elem in listaEmailuriExtrase)
            {
                incarcaRand(this.dgvEmail.Rows[this.dgvEmail.Rows.Add()], elem);
            }

            this.dgvEmail.FinalizeazaContructieRanduri();
        }
 private void getMesageDinCategorii(BEmail pEmail, IEnumerable <IMessageSummary> pTipFolder, MessageFlags pFlag)
 {
     foreach (var mail in pTipFolder)
     {
         int nrAtasamente = 0;
         foreach (var attach in mail.BodyParts)
         {
             if (!string.IsNullOrEmpty(attach.FileName) && string.IsNullOrEmpty(attach.ContentId))
             {
                 nrAtasamente++;
             }
         }
         BEmailuriExtrase.Add(pEmail.Id, getIndiceFlag(pFlag), nrAtasamente, getData(mail.Date), mail.Envelope.Subject, mail.Envelope.From.ToString(), mail.Envelope.To.ToString(), (int)mail.UniqueId.Id, string.Empty, null);
         this.pbIncarcaEmailuri.PerformStep();
         nrAtasamente = 0;
     }
 }
示例#3
0
        private void incarcaRand(DataGridViewRow pRand, BEmailuriExtrase pElem)
        {
            pRand.Tag = pElem;
            DataGridViewPersonalizat.InitCelulaDeschideClasic(pRand);
            if (pElem.NumarAtasamente != 0)
            {
                DataGridViewPersonalizat.initCelulaImagine(pRand, EnumColoaneDGV.colAttachment.ToString(), (System.Drawing.Image)Properties.Resources.attachment);
            }
            else
            {
                DataGridViewPersonalizat.initCelulaImagine(pRand, EnumColoaneDGV.colAttachment.ToString(), new Bitmap(1, 1));
            }

            pRand.Cells[EnumColoaneDGV.colSender.ToString()].Value  = pElem.Expeditor;
            pRand.Cells[EnumColoaneDGV.colSubiect.ToString()].Value = pElem.Subiect;
            pRand.Cells[EnumColoaneDGV.colData.ToString()].Value    = pElem.DataServer;
        }
        private void getMesageDinAll(BEmail pEmail, IEnumerable <IMessageSummary> pTipFolder)
        {
            List <DateTime> lista = BEmailuriExtrase.GetListUniqueId(pEmail.Id, CDL.iStomaLab.CDefinitiiComune.EnumStare.Activa, null);

            foreach (var mail in pTipFolder)
            {
                int nrAtasamente = 0;
                foreach (var attach in mail.BodyParts)
                {
                    if (!string.IsNullOrEmpty(attach.FileName) && string.IsNullOrEmpty(attach.ContentId))
                    {
                        nrAtasamente++;
                    }
                }
                if (!lista.Contains(getData(mail.Date)))
                {
                    BEmailuriExtrase.Add(pEmail.Id, getIndiceFlag(mail.Flags), nrAtasamente, getData(mail.Date), mail.Envelope.Subject, mail.Envelope.From.ToString(), mail.Envelope.To.ToString(), (int)mail.UniqueId.Id, string.Empty, null);
                    this.pbIncarcaEmailuri.PerformStep();
                    nrAtasamente = 0;
                }
            }
        }