# C1.Win.Schedule.C1Schedule.AppointmentCustomAction

## Content

<div class="doc-site-dotnet-api-container">




<h1 id="C1_Win_Schedule_C1Schedule_AppointmentCustomAction" data-uid="C1.Win.Schedule.C1Schedule.AppointmentCustomAction" class="text-break">AppointmentCustomAction Event
</h1>
<div class="markdown level0 summary"><p>Occurs immediately before a custom action of an <span class="xref">C1.Schedule.Appointment</span> object executes.</p>
</div>
<div class="markdown level0 conceptual"></div>
<h6><strong>Namespace</strong>: <a class="xref" href="C1.Win.Schedule.html">C1.Win.Schedule</a></h6>
<h6><strong>Assembly</strong>: C1.Win.Schedule.10.dll</h6>
<h5 id="C1_Win_Schedule_C1Schedule_AppointmentCustomAction_syntax">Syntax</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">[C1Category(&quot;Appointment&quot;)]
[C1Description(&quot;AppointmentCustomAction&quot;, &quot;Fired when a custom action of an Appointment executes.&quot;)]
public event CancelAppointmentEventHandler AppointmentCustomAction</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">&lt;C1Category(&quot;Appointment&quot;)&gt;
&lt;C1Description(&quot;AppointmentCustomAction&quot;, &quot;Fired when a custom action of an Appointment executes.&quot;)&gt;
Public Event AppointmentCustomAction As CancelAppointmentEventHandler</code></pre>
</div>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><span class="xref">CancelAppointmentEventHandler</span></td>
      <td>Occurs immediately before a custom action of an  object executes.</td>
    </tr>
  </tbody>
</table>
<h5 id="C1_Win_Schedule_C1Schedule_AppointmentCustomAction_remarks"><strong>Remarks</strong></h5>
<div class="markdown level0 remarks"><p>To cancel default handling, set CancelAppointmentEventArgs.Cancel property to true.</p>
</div>
<h5 id="C1_Win_Schedule_C1Schedule_AppointmentCustomAction_examples"><strong>Examples</strong></h5>
<pre><code class="lang-csharp">private void c1Schedule1_AppointmentAdded(object sender, AppointmentEventArgs e)
{
	// create a new action
	Action action = new Action();
	action.Command = "http://www.grapecity.com";
	// set appointment action
	e.Appointment.Action = action;
}</code></pre>

</div>
