Select to view content in your preferred language

Always Have Point Symbol Angle to Road

130
2
3 weeks ago
AustinShaw
Emerging Contributor

I have a series of point features where the symbology has been set up to rotate based on a field.  My client wants these Red Triangles to always point at the road.  This works for most situations but on larger projects I end up with situations like this...

On this sheet the Red Triangles are pointing to the road as intended, but...

AustinShaw_1-1747144442238.png

There is another page in the Map Series that shows this area, from a different angle.  But now the points are no longer pointing at the road.

AustinShaw_2-1747144539292.png

I could just Export to PDF the first half of the job, then change the rotation on this page and export the second half of the job.  But some of these projects have dozens of sheets in the map series like this.

Is there anyway to set up the symbol rotation to always point to a fixed geographic point or based on the Map Series rotation?

 

0 Kudos
2 Replies
MicZatorsky_AEC
Frequent Contributor

You could write a script that finds the nearest road to a triangle marker. For the nearest road, calculate the road bearing using Calculate Geometry Attributes, and use that to calculate the perpendicular angle for point rotation. Populate a point attribute with the required angle and use that with the symbology config. 
There could be some challenge with being 180 degrees out based on the road angle and which side of the road the point is on, though.


0 Kudos
AustinShaw
Emerging Contributor

Apologies, I forgot to post about my work around.  But thank you to MicZatorsky for the suggestion.

Since the Red Triangles were purely visual and had no data relevant to my tables, I added in duplicate point on top of the originals.  Then after setting up a field in the Red Triangles to store what page of the Map Series each one was on I updated the duplicate points to display the alternate page of the Map Series (ie the original ones were set to 3 and the duplicate ones were set to 13)

This is the bit of Arcade I used in the Field Calculator to do that for me:

var polygons = FeaturesetByName($datastore, "MapCuts")

var i_polygon = First(Intersects(polygons, $feature))

if(i_polygon == null) { return null }

return i_polygon.Sheet_Number

Then I added a copy of the Red Triangle feature layer to the map and set up Page Query in the layer properties to only display when the new Map Series field matches the active Page Number.

 AustinShaw_0-1748974906312.png

This made it so on Page 3 the original points displayed facing the road with the Page 13 points hidden

Then on page 13 the original points displayed facing the road with the original points hidden.

 

0 Kudos