예제 #1
0
        public static void scheduler_InitAppointmentDisplayText_1(object sender, AppointmentDisplayTextEventArgs e)
        {
            SchedulerControl   scheduler = sender as SchedulerControl;
            IAppointmentStatus status    = scheduler.DataStorage.Appointments.Statuses.GetById(e.Appointment.StatusKey);

            e.Description = String.Format("Status Info:\nDisplayName = '{0}'\nID = '{1}'", status.DisplayName, status.Id.ToString());
        }
예제 #2
0
        public static void scheduler_InitAppointmentDisplayText(object sender, AppointmentDisplayTextEventArgs e)
        {
            SchedulerControl  scheduler = sender as SchedulerControl;
            IAppointmentLabel label     = scheduler.DataStorage.Appointments.Labels.GetById(e.Appointment.LabelKey);

            e.Description = String.Format("Label Info:\nDisplayName = '{0}'\nID = '{1}'", label.DisplayName, label.Id.ToString());
        }
예제 #3
0
 private void scheduler_InitAppointmentDisplayText(object sender, AppointmentDisplayTextEventArgs e)
 {
     if (e.ViewInfo.Appointment.GetRow(storage) is CapacityRequirement capReq &&
         capReq.RoomBooking != null)
     {
         e.Text = $"{e.Appointment.Subject} ({capReq.RoomBooking.Room.Name})";
     }
 }
 private void schedulerControl1_InitAppointmentDisplayText(object sender, AppointmentDisplayTextEventArgs e)
 {
     // Display custom text in Day and WorkWeek views only (VerticalAppointmentViewInfo).
     if (e.ViewInfo is VerticalAppointmentViewInfo && e.Appointment.CustomFields["ApptAddInfo"] != null)
     {
         e.Text  = e.Appointment.Subject + "\r\n";
         e.Text += "------\r\n";
         e.Text += e.Appointment.CustomFields["ApptAddInfo"].ToString();
     }
 }
예제 #5
0
        private void scheduler_InitAppointmentDisplayText(object sender, AppointmentDisplayTextEventArgs e)
        {
            Appointment appointment = e.Appointment;

            if (appointment.IsRecurring)
            {
                appointment = e.Appointment.RecurrencePattern;
            }
            DevExpress.Persistent.Base.General.IEvent obj = (DevExpress.Persistent.Base.General.IEvent)listEditor.SourceObjectHelper.GetSourceObject(appointment);
            e.Text = string.Format("{0}-({1})", e.Text, obj.GetHashCode());
        }
예제 #6
0
        private void schedulerControl1_InitAppointmentDisplayText(object sender, AppointmentDisplayTextEventArgs e)
        {
            string[]      stringArray = e.Text.Split(' ');
            StringBuilder builder     = new StringBuilder();

            foreach (string str in stringArray)
            {
                builder.Append(string.Concat("<color=", r.Next(0, 255), ",", r.Next(0, 255), ",", r.Next(0, 255), ">", str, " ", "</color>"));
            }
            e.Text = builder.ToString();
        }
        private void OnInitAppointmentDisplayText(object sender, AppointmentDisplayTextEventArgs e)
        {
            try {
                Model.Appointment.ItemCode itemType
                    = (Model.Appointment.ItemCode)e.Appointment.CustomFields["ItemType"];

                e.Text = Enum.GetName(typeof(Model.Appointment.ItemCode), itemType) + ": " +
                         e.Appointment.Subject;
            } catch {
            }
        }
예제 #8
0
 public static void scheduler_InitAppointmentDisplayText(object sender, AppointmentDisplayTextEventArgs e)
 {
     // Display custom text in Day and WorkWeek views only (VerticalAppointmentViewInfo).
     if (e.ViewInfo is VerticalAppointmentViewInfo)
     {
         e.Text  = e.Appointment.Subject + "\r\n";
         e.Text += "------\r\n";
         if (e.Description != String.Empty)
         {
             e.Description = string.Empty;
             e.Text       += "Description is hidden";
         }
     }
 }
예제 #9
0
        private void schedulerControl1_InitAppointmentDisplayText(object sender, AppointmentDisplayTextEventArgs e)
        {
            MyAppointment a = e.Appointment.GetSourceObject(schedulerStorage1) as MyAppointment;

            if (a == null)
            {
                return;
            }
            if (a.Customer != null)
            {
                //    e.Description = "Queste sono le note dell'appuntamento";
                //    e.Text = "prova per il 2";
                string resDes = "";
                if (a.Resource != null)
                {
                    //verifico che succede
                    resDes = a.Resource.Descrizione;
                }

                e.Text = string.Format("{0} ({1} {2}-{3})", resDes, a.Customer.Cognome, a.Customer.Nome, e.Appointment.Location);
            }
        }
예제 #10
0
        private void scheduler_InitAppointmentDisplayText(object sender, AppointmentDisplayTextEventArgs e)
        {
            Appointment appointment = e.Appointment;

            if (appointment.IsRecurring)
            {
                appointment = e.Appointment.RecurrencePattern;
            }
            Schedule obj = (Schedule)listEditor.SourceObjectHelper.GetSourceObject(appointment);
            string   ScheduleLocation;

            if (obj.MeetingRoom != null)
            {
                ScheduleLocation = obj.MeetingRoom.Name;
            }
            else
            {
                ScheduleLocation = "Out of Office";
            }
            e.Text        = string.Format("{0}-({1})", obj.Subject, ScheduleLocation);
            e.Description = string.Format("{0} Participant(s): {1}", obj.Description, obj.Participants);
        }
        private void schedulerControl1_InitAppointmentDisplayText(object sender, AppointmentDisplayTextEventArgs e)
        {
            CustomObject obj = e.Appointment.CustomFields[CustomFieldName] as CustomObject;

            e.Description = (obj != null) ? obj.ToString() : "(no custom info)";
        }
예제 #12
0
 private void schedulerControl1_InitAppointmentDisplayText(object sender, AppointmentDisplayTextEventArgs e)
 {
     e.Text        = e.Description;
     e.Description = "";
 }
        private void schedulerControl1_InitAppointmentDisplayText(object sender, AppointmentDisplayTextEventArgs e)
        {
            object contactInfo = e.ViewInfo.Appointment.CustomFields[OutlookUserPropertyName];

            e.Text = string.Format("{0} (Contact Info: {1})", e.ViewInfo.Appointment.Subject, (contactInfo == null ? "N/A" : contactInfo.ToString()));
        }
예제 #14
0
        private void schedulerControl_InitAppointmentDisplayText(object sender, AppointmentDisplayTextEventArgs e)
        {
            Resource resource = schedulerStorage.Resources.GetResourceById(e.Appointment.ResourceId);

            e.Text += " " + resource.Caption;
        }
 protected void ASPxScheduler1_InitAppointmentDisplayText(object sender, AppointmentDisplayTextEventArgs e)
 {
     e.Description = string.Format("Price: {0:c}", e.Appointment.CustomFields["Field1"]);
 }
예제 #16
0
        //protected void ASPxScheduler1_AppointmentFormShowing(object sender, DevExpress.Web.ASPxScheduler.AppointmentFormEventArgs e)
        //{
        //    e.Container.Caption = e.Container.IsNewAppointment ? "Create New Appointment" : "Edit Appointment: " + e.Appointment.Subject;
        //}

        protected void ASPxSchedulerControl1_InitAppointmentDisplayText(object sender, AppointmentDisplayTextEventArgs e)
        {
            //apt.subject is pilotID, either call stored procedure to find pilot name or search locally
            Appointment apt = e.Appointment;

            Console.WriteLine(apt.Location);
            if (apt.Location == "")
            {
                e.Text = String.Format("{0}", apt.Subject);
            }
            else
            {
                e.Text = String.Format("[{0}] {1}", apt.Location, apt.Subject);
                //e.Description = String.Format("Details: {0}", apt.Description);
            }
        }
예제 #17
0
    protected void ASPxScheduler1_InitAppointmentDisplayText(object sender, AppointmentDisplayTextEventArgs e)
    {
        Appointment apt = e.Appointment;

        e.Text = apt.Subject;
    }