Select to view content in your preferred language

Line Scalling/Labeling issue

677
3
08-10-2012 12:18 PM
MarkPaulson
Occasional Contributor
Complete Noob with this stuff and I apologize if this is stupidly simple. I have a feature layer in my MXD that uses the cartographic line symbol with a template spacing of 6. I also have a Label field with a placement of curved.  when I add the layer using esri.layers.ArcGISDynamicMapServiceLayer evrything is correct. When is use esri.layers.FeatureLayer the scalling is different and the label is missing. Images attached showing difference.
0 Kudos
3 Replies
MarkPaulson
Occasional Contributor
I could sure use some help with this please.
0 Kudos
by Anonymous User
Not applicable
Original User: jgravois

I took a look at this and was able to reproduce some quirky display behavior for the featureLayer with a cartographic line type.  I am not 100% sure on the expected behavior here, but based on the limitations for symbology for feature services in general, it may be that the Javascript API does not support cartographic line types for featureLayers either.

from "Authoring feature services"
"For line layers, simple line symbols are supported. If other symbols are used, the feature service converts them to a simple line symbol that best represents the original symbol...."
http://resources.arcgis.com/en/help/main/10.1/index.html#//0154000003nt000000

With regard to labels, its my understanding that labels from the underlying map service are not going to come across when working with feature layers either.

Given these limitations you might want to consider loading the dynamic map service instead and using a feature layer referencing the same data in selection mode only.  This will allow you to display the original tiles and only retrieve geometry for the feature layer onClick.

Here is a sample of the implementation:
http://help.arcgis.com/en/webapi/javascript/arcgis/help/jssamples/ed_attribute_inspector.html
0 Kudos
MarkPaulson
Occasional Contributor
Thank you so much.
0 Kudos