skyline读取适量文件属性
featurelayer = sgworld.Creator.CreateFeatureLayer("longjingguoji","FileName=D:\\data\\longjingguoji.shp;TEPlugName=OGR;","");
featurelayer.Streaming = false;
featurelayer.Refresh();
var features = featurelayer.FeatureGroups.Polygon.Features;
for(var i=0; i < features.Count; i++){
var featuree = features.Item(i);
var geometryy = featuree.Geometry;
console.log(geometryy);
var attribute = featuree.FeatureAttributes;
console.log(attribute);
console.log(attribute.Count);
break;
}
注意: 加载方式与流方式和层方式有关
如果为流方式,如果当前视图下没有加载, 是获取不到属性信息的
转载自:https://blog.csdn.net/wt346326775/article/details/56479785