Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by Brandon on Mar 09, 2009 13:24
open dhtmlx forum
Subgrid Style

Is it possible to set a subgrids style to be different than the parent grid?
Answer posted on Mar 10, 2009 02:29
Yes, it's possible. If you are loading subgrid via xml you can set grid's style directly into xml. You should add following lines into you xml:
 <head>
<beforeInit>
<call command="setSkin"><param>xp</param></call>
</beforeInit>
</head>
Please see more examples here http://dhtmlx.com/docs/products/dhtmlxGrid/samples/initialization_loading/pro_config_ext.html

Also you can change subgrid style on the fly using "onSubGridCreated" event:
grid.attachEvent("onSubGridCreated",function(sub,id,ind,value){
//sub - subgrid object
//value - value from XML for related cell