AnsweredAssumed Answered

Having problems with in-line variable substitution (I think?)

Question asked by AnchorPoint on Mar 6, 2015

Hello, Folks.

I am trying to write a program that pretty much duplicates the Polygon Neighbors command which will not work for me, no matter how I try (thanks, m-aware error message!). Anyway, I will eventually iterate through all of the polygons in a dataset, but I am trying to get it to work once, first, before working on the iteration. Currently, when the initial Select by Location command operates, it selects the initial polygon along with the adjacent ones. I want to remove the initial polygon so that the selection only includes the surrounding polygons. To do this, I want to store the FID value for the polygon as a variable that I can then use with the selection step that removes the initial polygon. I just can't figure out a way to hand the value I am trying to fish out with a Get Field Value operation to the removal step via an expression. The top two ovals are just my poor attempts at making things happen. Conceptually, I am assuming that some sort of link needs to happen between the Initial Polygon FID green oval and Expression light blue oval.

 

I am really new to this use of ModelBuilder, and to programming in general, so I very much appreciate any help anyone can offer.

 

Cheers,

 

Mark

Outcomes