This document is archived and information here might be outdated. Recommended version. |
ArcObjects namespaces > ArcMapUI > ESRI.ArcGIS.ArcMapUI > Interfaces > IS > ISpatialJoin Interface > ISpatialJoin.JoinWithin Method (ArcObjects .NET 10.4 SDK) |
Joins a feature in the source feature class with the feature if it falls within in the join feature class.
[Visual Basic .NET] Public Function JoinWithin ( _ ByVal pOutputName As IName _ ) As IFeatureClass
[C#] public IFeatureClass JoinWithin ( IName pOutputName );
JoinWithin identifies those features in the source table that are contained by features in the table being joined.
For example, if the source layer containing line features (rivers) is spatially joined to a layer which contains polygon features (administrative boundaries), with the LeftOuterJoin property set to TRUE, the new output layer will contain a record for each feature in the source table with all the attribute columns from the join table appended. Where a JoinWithin match was identified, each river in the new feature class will now have additional attribute information about the administrative boundary it falls within. Where no match was identified, the appended columns will be empty.
River and states feature classes:
New feature class table:
ISpatialJoin Interface | IFeatureClass Interface | Feature Class