AnsweredAssumed Answered

How to loop through layers in map and find certain layers

Question asked by mm166368 on Feb 21, 2017
Latest reply on Feb 21, 2017 by mitchh300

Hi,

 

I was recently given a python test/exercise at work. I'm not sure how to start this particular exercise so if anyone has any suggestions or a sample recipe/code, I would really appreciate it if you can share it with me.

The exercise I was given is:

I have two layers in my mxd which I'll be working off of which are a CITY LAYER and a SEWER MANHOLE LAYER

 

1.) Loop through layer in map and find the manhole layer and the city layer

2.) Cursor through each record in the city layer

3.) Print city name and how many manholes are within each city layer.

Outcomes