AnsweredAssumed Answered

Point.within(layer)

Question asked by Aylo420 on Nov 28, 2018
Latest reply on Nov 30, 2018 by bixb0012

import arcpy

 

sr = arcpy.SpatialReference(4326)

Laye = arcpy.mp.LayerFile(r'X:\Polygone.lyr')

lyr = Laye.listLayers("*")[0]

point = arcpy.PointGeometry(arcpy.Point(Var_x1, Var_y1), sr)
print(point.within(lyr))

 

I'm doing something wrong.

I'm trying to get a Boolean awser if True or False point is in a .lyr file

 

Does anyone see what's wrong?

 

Thx alot

Outcomes