Select to view content in your preferred language

Relates Relates Relates

2593
10
07-16-2010 10:22 AM
WillHughes1
Occasional Contributor II
Has anyone been successful getting relates to work in the Flex Sample Viewer?

What I want is for the user to be able to click on a fire hydrant and get information from a related table, such as fire flow test info.

If anyone has an example of this please point me to the sample or post it on the Flex API resource page.

Thanks.

-Will
Tags (2)
0 Kudos
10 Replies
SasaI_
by
New Contributor
I use ArcObjects in a web service to get a collection of related records in 9.3.1 (10 is a LOT simpler).  Here's a code snippet:

IRelationshipClassCollection relClassCollection = (IRelationshipClassCollection)fl;
IEnumRelationshipClass relClasses = relClassCollection.RelationshipClasses;
IRelationshipClass rc = null;
while ((rc = relClasses.Next()) != null) {
    ISet relSet = rc.GetObjectsRelatedToObject(f);
    IRowBuffer rowBuffer = null;
    while ((rowBuffer = (IRowBuffer)relSet.Next()) != null)
    {...


where fl is your IFeatureLayer and f is your IFeature you want to get records for.
0 Kudos