• Please make sure the page has finished loading before you browse the FAQ list.


How to execute a PrT shortest path search by COM?

An example for a shortest path search between two nodes:

Set NetElementContainer = Visum.CreateNetElements
Set Node = Visum.Net.Nodes.ItemByKey(10)
NetElementContainer.Add Node
Set Node = Visum.Net.Nodes.ItemByKey(40)
NetElementContainer.Add Node
'Route search with current speed tCur
Set RouteSearchPrT = Visum.Analysis.RouteSearchPrT
VSysCode = 'C'
RouteSearchPrT.Execute NetElementContainer, VSysCode, 1

A more complex example, displaying the result into a list and write the path legs to an attribute file: