Scheduler for WPF | ComponentOne
C1.WPF.Schedule Namespace / C1Scheduler Class / AppointmentCustomAction Event
Example

In This Topic
    AppointmentCustomAction Event (C1Scheduler)
    In This Topic
    Occurs immediately before a custom action of an C1.C1Schedule.Appointment object executes.
    Syntax
    'Declaration
     
    
    Public Event AppointmentCustomAction As EventHandler(Of AppointmentActionEventArgs)
    public event EventHandler<AppointmentActionEventArgs> AppointmentCustomAction
    Event Data

    The event handler receives an argument of type AppointmentActionEventArgs containing data related to this event. The following AppointmentActionEventArgs properties provide information specific to this event.

    PropertyDescription
    Gets an Appointment object.  
    (Inherited from System.Windows.RoutedEventArgs)
    (Inherited from System.Windows.RoutedEventArgs)
    (Inherited from System.Windows.RoutedEventArgs)
    (Inherited from System.Windows.RoutedEventArgs)
    Remarks
    To cancel default handling, set CancelAppointmentEventArgs.Cancel property to true.
    Example
    private void c1Scheduler1_AppointmentAdded(object sender, AppointmentActionEventArgs e)
    {
    	// create a new action
    	Action action = new Action();
    	action.Command = "https://www.grapecity.com/en/componentone";
    	// set appointment action
    	e.Appointment.Action = action;
    }
    See Also