dojox.grid.DataGrid隐藏/禁用网格头

dojox.grid.DataGrid隐藏/禁用网格头,dojox.grid.datagrid,Dojox.grid.datagrid,我需要一个选项来隐藏dojox.grid.DataGrid中的标题。 什么也没找到。 非常感谢您提供的任何信息 您可以使用CSS: .dojoxGrid标头{display:none;} 此解决方案来自: 您可以使用CSS: .dojoxGrid标头{display:none;} 此解决方案来自: 我在dojo 1.6中使用(可能从dojo 1.3开始工作) 我在dojo 1.6中使用(可能从dojo 1.3开始工作) u可以在数据网格的postrender处连接。然后找到创建的headerGr

我需要一个选项来隐藏dojox.grid.DataGrid中的标题。 什么也没找到。 非常感谢您提供的任何信息

您可以使用CSS:

.dojoxGrid标头{display:none;}

此解决方案来自: 您可以使用CSS:

.dojoxGrid标头{display:none;}

此解决方案来自:

我在dojo 1.6中使用(可能从dojo 1.3开始工作)

我在dojo 1.6中使用(可能从dojo 1.3开始工作)


u可以在数据网格的postrender处连接。然后找到创建的headerGrid元素 然后将“样式显示”设置为“无”

 //workaround the grid calls postrender after
                            //the component is at the dom.
                            //so then i can change the style to reset the header to invisible
                            dojo.connect(grid,"postrender",function(){
                                  var headerGrid =this.domNode.firstElementChild;
                                    headerGrid.style.display="none";
                            });

u可以在数据网格的postrender处连接。然后找到创建的headerGrid元素 然后将“样式显示”设置为“无”

 //workaround the grid calls postrender after
                            //the component is at the dom.
                            //so then i can change the style to reset the header to invisible
                            dojo.connect(grid,"postrender",function(){
                                  var headerGrid =this.domNode.firstElementChild;
                                    headerGrid.style.display="none";
                            });

我建议改用datagrid而不是datagrid,这样会更好

隐藏标题的设置是属性“showHeader”,它是一个布尔值


看看这篇文章,它通过定义包括“showHeader”在内的网格结构来指导您。

我建议切换到使用,而不是使用datagrid,这样会更好

隐藏标题的设置是属性“showHeader”,它是一个布尔值


查看这篇介绍如何定义网格结构(包括“showHeader”)的文章。

谢谢,这应该在dojo文档中提到:-)谢谢,这应该在dojo文档中提到:-)