Cancelling OnClientAppointmentContextMenuItemClicked events

In my appointment context menu, I have a delete menu item that I would like to cancel if the user does not confirm that they are sure they want to delete this item. However, the args argument for OnClientAppointmentContextMenuItemClicked does not seem to have a "set_cancel" method in the same way as is the case on the OnClientAppointmentDeleting. Here is what I am trying to do:

function onAppointmentContextMenuItemClicked(sender, args) {

switch (args.get_item().get_value()) {

case "CommandDelete":

if (args.get_appointment().get_id().startsWith('booking'))

type = "booking";

else if (args.get_appointment().get_id().startsWith('fixture'))

type = "fixture";

if (!confirm("Are you sure you want to delete this " + type)) {

args.set_cancel(true);

}

break;

}

}

There is no set_cancel event on the args object, so I can't see how to cancel the callback to the server. Can you tell me how I can cancel it?

Registration for Q1 2011 What’s New Webinar Week is now open. Mark your calendar for the week starting March 21st and book your seat for a walk through all the exciting stuff we ship with the new release!

Progress, Telerik, and certain product names used herein are trademarks or registered trademarks of Progress Software Corporation and/or one of its subsidiaries or affiliates in the U.S. and/or other countries. See Trademarks or appropriate markings.