Warning: file_get_contents(/data/phpspider/zhask/data//catemap/5/actionscript-3/6.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/apache-flex/4.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Actionscript 3 检查FlexDataGrid列是否包含数据_Actionscript 3_Apache Flex_Flex3 - Fatal编程技术网

Actionscript 3 检查FlexDataGrid列是否包含数据

Actionscript 3 检查FlexDataGrid列是否包含数据,actionscript-3,apache-flex,flex3,Actionscript 3,Apache Flex,Flex3,有没有办法检查FlexDataGrid列是否为空?我试图搜索一个DataGridColumn,它允许我这样做,但我找不到任何数据。如果您的意思是说该GridColumn的值对于所有行都为null,那么此代码段应该可以工作: //myDG is the datagrid var allNull:Boolean=true; for each(var o:Object in myDG.dataProvider) { if(o.myColumnName != null) { al

有没有办法检查FlexDataGrid列是否为空?我试图搜索一个DataGridColumn,它允许我这样做,但我找不到任何数据。

如果您的意思是说该GridColumn的值对于所有行都为null,那么此代码段应该可以工作:

//myDG is the datagrid
var allNull:Boolean=true;
for each(var o:Object in myDG.dataProvider) {
    if(o.myColumnName != null) {
        allNull=false;
        break;
    }
}

trace(allNull); //false = all is not null, true = everything in that column is null

如果您的意思是说该GridColumn的值对于所有行都为null,那么此代码段应该可以工作:

//myDG is the datagrid
var allNull:Boolean=true;
for each(var o:Object in myDG.dataProvider) {
    if(o.myColumnName != null) {
        allNull=false;
        break;
    }
}

trace(allNull); //false = all is not null, true = everything in that column is null

空的??你的问题不是很清楚。请clarify@PranavHosangadi我的意思是它不包含任何数据…空??你的问题不是很清楚。请clarify@PranavHosangadi我的意思是它不包含任何数据。。。