Solved! Go to Solution.
var layerDetails:LayerDetails = new LayerDetails(); featureLayer.featureCollection = new FeatureCollection(featureSet, layerDetails);
Leonardo,
That is because the ShapeFile widget adds the shapefiles to a graphics layer and not a normal type that would show in the TOC.
Don't forget to click the Mark as answer check on this post and to click the top arrow (promote).
Follow these steps as shown in the below graphic:
var layerDetails:LayerDetails = new LayerDetails(); featureLayer.featureCollection = new FeatureCollection(featureSet, layerDetails);
Leonardo,
The featureCollection needs a LayerDetailsvar layerDetails:LayerDetails = new LayerDetails(); featureLayer.featureCollection = new FeatureCollection(featureSet, layerDetails);
I will be coming out with an enhanced Shapefile widget very soon that handles re-projecting the shapefile and adding each shapefile and labels as different layers in the TOC, as well as other features.
Leonardo,
Here is the link
http://www.arcgis.com/home/item.html?id=2e9096c5d5044d39a264df759611686f
Leonardo,
Did you read the readme.txt where it said you need to use an ArcGIS Server 10 Geometry Service.