Hi,
We want to prompt a user to confirm drag drop operations using RadConfirm. In client script, we can tell the user the target destination, drop position, etc. and are using the following javascript which, after confirm is acknowledged, calls function reorder
function onClientNodeDropping(sender, eventArgs)
{
if (eventArgs.get_destNode().get_category() == "Folder")
{
DropPos = eventArgs.get_dropPosition();
radconfirm("Are You Sure you want to change the order of " + eventArgs.get_sourceNode().get_text() + " and move it " + eventArgs.get_dropPosition() + " " + eventArgs.get_destNode().get_text() + "?", reorder);
}
}
function reorder()
{
var tree= $find("<%= RadTreeView1.ClientID %>");
var node = tree.get_selectedNode();
if (node.get_category() == "Folder")
{
$find("<%=RadAjaxManager1.ClientID %>").ajaxRequest("DRAGFOLDER|" + null + "|" + node.get_value() + "|" + tree.get_dropPosition());
}
After that, the ajaxrequest handler is used. The problem is that tree.get_dropPosition() does not work in this scenario. We have tried the alternate approach and not used ajax and just tried to use the server-side NodeDrop Event handler which works very well except there is no way that I can find to block it from firing prior to the radConfirm prompt - it just immediately fires. Does anyone know of a way to achieve the desired outcome described above?
We want to prompt a user to confirm drag drop operations using RadConfirm. In client script, we can tell the user the target destination, drop position, etc. and are using the following javascript which, after confirm is acknowledged, calls function reorder
function onClientNodeDropping(sender, eventArgs)
{
if (eventArgs.get_destNode().get_category() == "Folder")
{
DropPos = eventArgs.get_dropPosition();
radconfirm("Are You Sure you want to change the order of " + eventArgs.get_sourceNode().get_text() + " and move it " + eventArgs.get_dropPosition() + " " + eventArgs.get_destNode().get_text() + "?", reorder);
}
}
function reorder()
{
var tree= $find("<%= RadTreeView1.ClientID %>");
var node = tree.get_selectedNode();
if (node.get_category() == "Folder")
{
$find("<%=RadAjaxManager1.ClientID %>").ajaxRequest("DRAGFOLDER|" + null + "|" + node.get_value() + "|" + tree.get_dropPosition());
}
After that, the ajaxrequest handler is used. The problem is that tree.get_dropPosition() does not work in this scenario. We have tried the alternate approach and not used ajax and just tried to use the server-side NodeDrop Event handler which works very well except there is no way that I can find to block it from firing prior to the radConfirm prompt - it just immediately fires. Does anyone know of a way to achieve the desired outcome described above?