Exemplo n.º 1
0
        public void LoadJRIntoListbox()
        {
            var requests = _dataservice.getAllRequests();

            Requests.Clear();
            foreach (var request in requests)
            {
                Requests.Add(request);
            }
        }
Exemplo n.º 2
0
        private void timer_Tick(object sender, EventArgs e)
        {
            //Date kan aangepast worden naar keuze
            DateTime emailSendTime = new DateTime(DateTime.Now.Year, DateTime.Now.Month, DateTime.Now.Day, 9, 17, 0); //18pm,0min,0sec
            DateTime dateNow       = DateTime.Now;

            if (_dataservice.getAllRequests() != null)
            {
                //geen mail op zaterdag & zondag
                if (dateNow.DayOfWeek != DayOfWeek.Saturday || dateNow.DayOfWeek != DayOfWeek.Sunday)
                {
                    if (emailSendTime.Hour == dateNow.Hour && emailSendTime.Minute == dateNow.Minute)
                    {
                        SendMail();
                    }
                }
            }
        }