This document is archived and information here might be outdated.  Recommended version.


ISpatialJoin.JoinWithin Method (ArcObjects .NET 10.8 SDK)
ArcObjects Help for .NET developers > ArcObjects Help for .NET developers > ArcObjects namespaces > ArcMapUI > ESRI.ArcGIS.ArcMapUI > Interfaces > IS > ISpatialJoin Interface > ISpatialJoin.JoinWithin Method
ArcGIS Developer Help

ISpatialJoin.JoinWithin Method

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
);

Product Availability

Available with ArcGIS Desktop.

Remarks

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:

               

 

 

 

See Also

ISpatialJoin Interface | IFeatureClass Interface | Feature Class