ThinkGeo.com    |     Documentation    |     Premium Support

Drawing one-way streets in the map

Hello,


I have an shp file containing a column name called ONE_WAY_ , it has diferents values for one-way and two-way roads based on the order of the start and end nodes,  the order is determined by the way the shapefile is digitized, value=0 for both direction or two-way roads, value = 1 for one-way roads direction going from first node to last one and value = 2  for one-way roads direction going from last node to first one.


Is it posible to draw an arrow in the streets like googlemaps do?


Best regards,


Leandro



 


Leandro,
 
We have a sample which shows side view icon in code community, you just need change the car icon to your arrow icon.
code.thinkgeo.com/projects/show/sideviewicon
 

Please let me know if you have more questions
Thanks
 
James

Leandro, 
  
 Actually, the project referenced in the Code Community shows a slightly different issue. It shows how to rotate icons based on the direction of the vehicle. Although the basic math is the same, it needs to be used differently. I am currently working on the exact solution for your case. Thank you.

Please, check the new project "Displaying One-Way Streets" on the Code Community. We created a LineStyle for displaying one way streets for the shapefile that comes in the sample app "Route on One-Way Roads" of Map Suite Routing extension. Based on that example, I think that you will find it intuitive to adapt the LineStyle to your case. Tomorrow, we will update the project to have a more generic LineStyle that will handle every case including yours. 



code.thinkgeo.com/projects/show/onewaystreets




Please, check a new file OneWayLineStyle2.cs on the Code Community , this style responds exactly to your case, I think. 
 Thank you.

Hello Val, 
  
 Sorry for the delay answering your replay, I’ve tried the proyect and it worked really well, thank you very much for your quick responce and great job. Happy holidays

I am glad that works well for you. I also thank you for your idea. I think that the OneWayLineStyle can be helpfull for a lot of people working with street network and for our Routing product.