Hello,
When I follow this Drag and Drop example, I'd like to also use the contextmenu on the RadGrid to add, edit or delete an appointment. I've already managed to get the add and edit-part working, but how do I delete an appointment this way?! Would it be possible to delete an appointment by ID?
When I follow this Drag and Drop example, I'd like to also use the contextmenu on the RadGrid to add, edit or delete an appointment. I've already managed to get the add and edit-part working, but how do I delete an appointment this way?! Would it be possible to delete an appointment by ID?
function contextMenuItemClicked(sender, args) { |
var action = args.get_item().get_value(); |
var radGridClickedRowIndex = document.getElementById("radGridClickedRowIndex").value; |
var grid = $find('<%= UnscheduledGrid.ClientID %>'); |
var masterTableView = grid.MasterTableView; |
var row = masterTableView.get_dataItems()[radGridClickedRowIndex]; |
var cell = masterTableView.getCellByColumnUniqueName(row, "AppointmentID"); |
if (action == "Add") { |
NewUnscheduledAppointment(); |
} |
if (action == "Edit") { |
ShowAppointment(cell.innerHTML); |
} |
if (action == "Delete") { |
//How to delete an appointment by ID?! |
} |
} |