Public_Seed_Grounds_lyr = "Public_Seed_Grounds_lyr" arcpy.MakeFeatureLayer_management(Public_Seed_Grounds_shp, Public_Seed_Grounds_lyr, "\"SEEDGRND\" = 'Lake Felicity'") arcpy.SelectLayerByLocation_management(VMS_InsideSDG, "INTERSECT", Public_Seed_Grounds_lyr, "1 Miles", "NEW_SELECTION")
Add these lines before your select by location, change your select by location to the new feature layer. Public_Seed_Grounds_lyr = "Public_Seed_Grounds_lyr" arcpy.MakeFeatureLayer_management(Public_Seed_Grounds_shp, Public_Seed_Grounds_lyr, "\"SEEDGRND\" = 'Lake Felicity'") arcpy.SelectLayerByLocation_management(VMS_InsideSDG, "INTERSECT", Public_Seed_Grounds_lyr, "1 Miles", "NEW_SELECTION")
Signed in members can post, follow updates, and more. New here? Register a free account.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.