Question

Removing Items from after successful test


Badge +9

Hello all,

I have a DWG file that has distance labels (text) and lines that I need to attach the text to.

I have figured out, mostly through assistance through this forum (thank you), how to get the closest features to match but what I am having trouble with is where the text label is not the closest feature.

I have used the Neighbor Finder and then a feature merger but for the ones that don't merge I want to be able to do a second test to look through the list of the other lines that are in the closest lines list.

I have done this by using a List Exploder, followed by a length calculator and then a tester. My issue is that if I have found the closest 5 features to the label and the test is successful on one of them, how do I ignore the other four in the test? In some cases no matches will be found, so in this case I need to keep the failed record.

 

Any assistance or guidance into how to do this better is very much appreciated.

Thanks

 

Dean


4 replies

Userlevel 1
Badge +21

What is your test? Is it something that can be done without exploding the list?

Badge +9

What is your test? Is it something that can be done without exploding the list?

Thanks @egomm I am trying to test the length of the closest 5 lines to see which one matches the text label. The neighbors finder gives me the list but it is not always the closest label.

Userlevel 1
Badge +21

What is your test? Is it something that can be done without exploding the list?

I was thinking an option might be to add the length to the list created in the neighbourfinder then using a listsearcher to find the match.

 

Badge +9

I was thinking an option might be to add the length to the list created in the neighbourfinder then using a listsearcher to find the match.

 

Thanks @egomm, yes that did the trick, although it did introduce an issue around string comparison as 11.7 is not the same as 11.70, so might need to do some pre-work on the values before testing. The upside it brought the test down from six transformers to two :)

 

Reply