Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted on Feb 13, 2007 15:22
open dhtmlx forum
1) I have a menu with a menu item called “Rename” – when I click that my folder should be in edit mode. s...

1) I have a menu with a menu item called “Rename” – when I click that my folder should be in edit mode. suggest me how to do that.

2) After selecting a node and when I click delte key I need to call a function – please give me a example.

Answer posted on Feb 13, 2007 15:24

1. You must define a custom onclick handler by

            menu.setOnClickHandler

(user defined function will receive a menuItem id and tree item id as first and second parameters.)

 and on clicking Rename button call next code for tree

            tree.editItem(tree_item_id);

 2. There are no such functionality available by default. But you can extend existing keyboard_navigation functionality.

           dhtmlXTreeObject.prototype._onkey_delete=function(){

                  //your onDelete code

          }

          tree.assignKeys([["delete",key_code_of_delete_key]]);

Answer posted by sematik (Support) on Dec 11, 2014 09:04

The information connected with xml to datagrid and google calendar week view also can help you, so please check it too.