Beispiel #1
0
        void AddImageByIndex(AppointmentImageInfoCollection c, int index)
        {
            AppointmentImageInfo info = new AppointmentImageInfo();

            info.ImageIndex = index;
            c.Add(info);
        }
        private void schedulerControl1_InitAppointmentImages(object sender, AppointmentImagesEventArgs e)
        {
            AppointmentImageInfoCollection c = e.ImageInfoList;

            CustomObject obj = e.Appointment.CustomFields[CustomFieldName] as CustomObject;

            AppointmentImageInfo info = new AppointmentImageInfo();

            if ((obj != null) && (obj.Picture != null))
            {
                info.Image      = obj.Picture;
                info.ImageIndex = 2;
                c.Add(info);
            }
        }
Beispiel #3
0
        private void timelineCells1_InitAppointmentImages(object sender, DevExpress.XtraScheduler.AppointmentImagesEventArgs e)
        {
            Appointment apt = e.Appointment;
            Assignment  ass = apt.GetSourceObject(this.schedulerControlPrintAdapter1.SchedulerControl.Storage) as Assignment;
            AppointmentImageInfoCollection c = e.ImageInfoList;

            c.Clear();
            c.Images = imageCollection1;

            AddImageByIndex(c, SelectImage(ass));


            if (ass.CheckedIn)
            {
                AppointmentImageInfo info1 = new AppointmentImageInfo();
                info1.Image = Properties.Resources.Lock_Lock_icon16;
                //AppointmentImageInfo info1 = new AppointmentImageInfo();
                //info1.Image = Properties.Resources.openHS;
                c.Add(info1);
            }
        }