Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by GR on Jun 29, 2007 23:31
open dhtmlx forum
Redefining cell types

I need to redefine a tree cell (tree) to a combobox (co) cell. is this possible? Im trying using setCellExcelType and using it at onCellEdit event stage 0. The combobox is defined well, but I got a javascript error. In stage 2 of onCellEdit I need to change from combobox to tree again, using userdata to save the value and the combobox label to be displayed as a part of tree.  Do you have any example of how to do things like this?? I know this is a strange question but this is the best way to allow users to update/insert data in my system.
Answer posted on Jul 04, 2007 12:34
setCellExcelType can be used in such scenario, but "tree" excell is kind of special, it stores info about hierarchy, so redefining it can cause a problems..
If you have a selectbox with predefined list of values, you can just update code of dhtmlxTreeGrid.js and create a selectbox instead of input.

In dhtmlXTreeGrid.js

this.er.innerHTML="<textarea....
    can be replaced with
this.er.innerHTML="<select....

Basically it is possible to move existing functionality of "co" or "combo" excell in "tree" excell, but it is no so simple task.

Answer posted by Andrei (Support) on Dec 06, 2014 01:42

Having solved the problem mentioned above, you may also look through the possible related problems with undefined index $_get and javascript schedule calendar.