own cell editor for grid based on combo/select box

I need define new cell editor based on �coro� cell editor (or on some other combo/select box)

----------------------------------------------------------------------------------------

I am using JavaScript definition my new cell editor with name “mytest”:



function eXcell_mytest(cell){

this.base = eXcell_coro;

this.base(cell);

}



eXcell_mytest.prototype = new eXcell_coro;



(Functions �edit� , �getValue�, �setValue� and �detach� can be written later).

----------------------------------------------------------------------------------------

For definition of columns in dhtmlxGrid (and loading data) I am using �grid.loadXML(�getData.php�)�. XML content is like:



    Testfalse

    Title A

    Title B

    Title C

    �.

    

    �

    

    2

3

1



-------------------------------------------------------------------------------------------------

| I see now in grid values (2,3,1,�) instead content (�Tiltle B�, �Tiltle C�, �Tiltle A�). |

-------------------------------------------------------------------------------------------------



Is some way, how defining my own cell editor based on combo/select box?

Thanks, Ivo

The combo excell has custom set and get methods, so it not such simple task to create a custom version of it.
Please check attached sample

1207821317.ZIP (1.71 KB)


I found by experiments,
that name of custom cell editor based on �coro� must start with �co string.



Name �mytest� in my example above (in question) don�t work. But same code with
name �co_mytest� works.<o:p></o:p>



<o:p></o:p>


Probably
this name can contain string �co� anywhere inside. <o:p></o:p>



I thing,
that relevant code in function:<o:p></o:p>



dhtmlXGridObject.prototype._parseHead
= function(xmlDoc) {<o:p></o:p>



�<o:p></o:p>


is <o:p></o:p>


                           for (var i=0;
i<headCol.length; i++){<o:p></o:p>



                                         if
((this.cellType[i].indexOf(‘co’)==0)||(this.cellType[i]==“clist”)){<o:p></o:p>



(line 4483
in my version of file: �dhtmlxGrid/sources/dhtmlxgrid.js).<o:p></o:p>



�.<o:p></o:p>

Actually the name must start from anything, but inline option tags will be processed only for column types started from co
Basically this feature was purposed for existing co|coro|combo types