Select to view content in your preferred language

Fields in FeatureDataForm

762
3
02-25-2011 11:07 AM
SteveLi
Emerging Contributor
Is there a way to specify which fields to be included in FeatureDataForm?

Thanks
0 Kudos
3 Replies
JenniferNery
Esri Regular Contributor
Yes, the FeatureDataForm's Fields is based on the OutFields of the FeatureLayer it is set to bind against. If you want to include/exclude fields, do not use "*" on your FeatureLayer.OutFields, instead specify the fields you want displayed on your FeatureDataForm.
0 Kudos
SteveLi
Emerging Contributor
Thanks for the reply, but I don't think the approach will solve my issue.

I actually need to customized FeatureDataForm, so the fields will be placed on different pages of a tabbed container.

I saw a Flex sample (Sorry, i am more familiar with Flex API than SL):

<esri:AttributeInspector id="attrInsp"
                                         deleteFeature="attrInsp_deleteFeatureHandler(event)"
                                         updateFeature="attrInsp_updateFeatureHandler(event)">

                    <esri:FieldInspector featureLayer="{myFeatureLayer}"
                                         fieldName="activeprod"
                                         label="ACTIVE_PRODUCTION"/>

                    <esri:FieldInspector featureLayer="{myFeatureLayer}"
                                         fieldName="field_name"
                                         label="FIELDNAME"/>

can specify which fields in the form.  Is there a way in SL to do that?

Thanks.
0 Kudos
JenniferNery
Esri Regular Contributor
Sure you can customize the existing FeatureDataForm, the source code can be downloaded from CodePlex. http://esrisilverlight.codeplex.com/

You also might want to look at this thread: http://forums.arcgis.com/threads/23331-How-to-create-a-non-editable-field-in-a-FeatureDataForm.
0 Kudos