Why does solve vehicle routing problem make directions in another language, Portuguese for example, and VRP Layer / Ribbon in ArcGIS Pro not? (With the same network dataset)
Thank you
Thanks again for the arcpy code. It works perfectly.
With adding layer and ribbon support to VRP in ArcGIS Pro 2.6 we also updated the schema of the solver. More details on that can be found here. Although the Solve Vehicle Routing Problem Tool did not have any changes to the tool functionality, it now goes through a bit of translation code to change the schema to the new format to send to the solver. We have seen some changes in the outputs between nulls and zeros as a result of this. If you are seeing functional differences please report these so we can look into them.
And if you are working within the ArcGIS Pro application, I would encourage you to look into using the layer and ribbon capabilities we added for VRP in ArcGIS Pro 2.6.
Thank you, I will see this over the weekend.
Ok. Thank you for the arcpy code. Over the weekend I will try to make the directions and explain the differences between the Solve Vehicle Routing Problem do Arcgis pro 2.5 and 2.6. One difference I can already say: Loading Orders, Depots, Breaks ... (all layers), the Arcgis pro 2.5 only loads selected records, and the Arcgis 2.6 loads all records.
Answering question 1:
There is no drop-down menu to select the directions language. You can select the language in the Directions geoprocessing tool, or you can set the directions language for a Vehicle Routing Problem layer using the following code in the python window:
<SPAN class="comment token"># Get the current ArcGIS Pro project</SPAN> proj <SPAN class="operator token">=</SPAN> arcpy<SPAN class="punctuation token">.</SPAN>mp<SPAN class="punctuation token">.</SPAN>ArcGISProject<SPAN class="punctuation token">(</SPAN><SPAN class="string token">"current"</SPAN><SPAN class="punctuation token">)</SPAN> <SPAN class="comment token"># Get the current map</SPAN> mapObj <SPAN class="operator token">=</SPAN> proj<SPAN class="punctuation token">.</SPAN>listMaps<SPAN class="punctuation token">(</SPAN><SPAN class="punctuation token">)</SPAN><SPAN class="punctuation token">[</SPAN><SPAN class="number token">0</SPAN><SPAN class="punctuation token">]</SPAN> <SPAN class="comment token"># Find the Vehicle Routing Problem layer in the map</SPAN> <SPAN class="comment token"># You might need to change the layer name string below if your layer's name is different.</SPAN> vrpLayerObj <SPAN class="operator token">=</SPAN> mapObj<SPAN class="punctuation token">.</SPAN>listLayers<SPAN class="punctuation token">(</SPAN><SPAN class="string token">"Vehicle Routing Problem"</SPAN><SPAN class="punctuation token">)</SPAN><SPAN class="punctuation token">[</SPAN><SPAN class="number token">0</SPAN><SPAN class="punctuation token">]</SPAN> <SPAN class="comment token"># Get the layer's solver properties</SPAN> solverProps <SPAN class="operator token">=</SPAN> arcpy<SPAN class="punctuation token">.</SPAN>na<SPAN class="punctuation token">.</SPAN>GetSolverProperties<SPAN class="punctuation token">(</SPAN>vrpLayerObj<SPAN class="punctuation token">)</SPAN> <SPAN class="comment token"># Set the directions language to Portugal Portuguese</SPAN> solverProps<SPAN class="punctuation token">.</SPAN>streetDirectionsProperties<SPAN class="punctuation token">.</SPAN>language <SPAN class="operator token">=</SPAN> <SPAN class="string token">"pt-PT"</SPAN><SPAN class="line-numbers-rows"><SPAN></SPAN><SPAN></SPAN><SPAN></SPAN><SPAN></SPAN><SPAN></SPAN><SPAN></SPAN><SPAN></SPAN><SPAN></SPAN><SPAN></SPAN><SPAN></SPAN><SPAN></SPAN></SPAN>
You do not need to install a language pack to get directions in Portuguese. All directions languages are available all the time, even without language packs. (This is new - ArcMap and older versions of ArcGIS Pro required a language pack installation to get directions in non-English languages.)
Answering question 2
We did not change the Solve Vehicle Routing Problem tool between ArcGIS Pro 2.5 and 2.6. Can you further explain your question?
Answering question 3
I am going to ask a colleague to help you with this question.
as for (2)
under the Network analyst section (quite a ways down)
What's new in ArcGIS Pro 2.6—ArcGIS Pro | Documentation
There is some information there, not sure it applies
I have little experience in Arcgis / Python, but I am interested.
Can you comment on the following? 1) When there is a Portuguese language pack for Arcgis pro 2.6 (currently only for 2.5) it will be possible to have directions in pt-PT (Portuguese) by Network Analysis dropdown menu?
Language pack available for 2.5:
2) Why in Arcgis pro 2.6 the "Solve Vehicle Routing Problem" works differently than in Arcgis pro 2.5?
3) Why in Arcgis pro 2.6 the Pickup Quantities field is null in output Geoprocessing \ Solve Vehicle Routing Problem?
Lastly, sorry for my English.
Thanks a lot for the help.
There is no ribbon or Directions pane setting for directions language at this time. However, you can run the Directions geoprocessing tool and select the desired language in that tool.
If that doesn't give you what you want, there is a way to set the VRP layer's directions language via python. Let me know if you want to learn about it.
Membros conectados podem postar, seguir atualizações e mais. Novo aqui? Registre uma conta gratuita.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.