Custom Edit Widget Pop-up

2163
2
11-30-2012 05:15 AM
AnthonyKeogh1
New Contributor III
I am working on a custom edit widget for Flex.
The widget will have the same functionality as the edit widget but it will also be able to create and edit features in a related
feature class.

So for example if you create a feature the editing pop-up will appear to allow you to enter the data for the feature based on the
fields for that feature type as it usually does.

The custom part is where the user can click an ???Add Related Feature??? button at the bottom of the pop-up.

This should then append to the current list of editable fields in the pop-up, or otherwise display, the fields for a feature in the
related feature class.
Also the relationship is one ??? many, so the user will want to click the ???Add Related Feature??? button multiple times, each time
adding all fields to the pop-up then enter their data.
When the user clicks the submit button both feature classes should be updated with the new data.

There is an example of editing a related feature so that part is ok,
the main question is does anybody know the best way to get the fields from the related feature class and display them in the
same manner as the normal edit widget pop-up?
I can???t see which file is doing the parsing and control creation for the current pop-up.
The only way I can think of to do it, is to query the layer for its fields and programmatically create the controls for each field.

Any ideas would be helpful.

Thanks,
Anthony
Tags (2)
0 Kudos
2 Replies
BjornSvensson
Esri Regular Contributor
Version 3.1 of the Flex API and Flex Viewer (being released this month) will have support for viewing and editing related records.  You might want to wait for that...  Even if you want to customize it further for your specific requirements, this will be a much better starting point.
0 Kudos
AnthonyKeogh1
New Contributor III
Thanks for the info Bjorn, I have already created a solution for my problem but I will also look into flex 3.1 also.
0 Kudos