directionsLanguage properties of RouterParameters

3497
6
07-06-2015 08:24 AM
lasinh
by
New Contributor III

I use directionsLanguage get router infomation, By default, NAServer gets installed with en_US only , how to add additional languages?

0 Kudos
6 Replies
KellyHutchins
Esri Frequent Contributor

Are you using the Directions Widget? If so try setting the directionsLanguage. See this post for details: Re: changing default instruction text in directions widget

0 Kudos
lasinh
by
New Contributor III

I use RouteTask.Set the routeParams directionsLanguage option in order to display the output directions in a particular language.

routeParams.directionsLanguage= "vi";

my code is not working!!

0 Kudos
KellyHutchins
Esri Frequent Contributor

It looks like Vietnamese is not one of the supported languages. See the directionsLanguage section of this help topic.

0 Kudos
MujeebAbdul
New Contributor

im do the same things as you write m but it is not working , is there configuration for the service

0 Kudos
lasinh
by
New Contributor III

hii Mujeeb Abdul! not configuration for the service.to change the default language. You find the resources.xml file in the path C:\Program Files\ArcGIS\Server\NetworkAnalyst\Directions\resources.xml and translate it your language. you can refer to Atlas Đồng Nai

0 Kudos
pixsnguyen
New Contributor

You can change the directionsLanguage by adding an argument to https://route.arcgis.com/arcgis/rest/services/World/Route/NAServer/Route_World to https://route.arcgis.com/arcgis/rest/services/World/Route/NAServer/Route_World/solve?directionsLanguage=vi 

Source: https://developers.arcgis.com/rest/network/api-reference/route-synchronous-service.htm

List of languages:

ar—Arabic
bs—Bosnian
ca—Catalan
cs—Czech
da—Danish
de—German
el—Greek
en—English
es—Spanish
et—Estonian
fi—Finnish
fr—French
he—Hebrew
hr—Croatian
hu—Hungarian
id—Indonesian
it—Italian
ja—Japanese
ko—Korean
lt—Lithuanian
lv—Latvian
nb—Norwegian
nl—Dutch
pl—Polish
pt-BR—Portuguese (Brazil)
pt-PT—Portuguese (Portugal)
ro—Romanian
ru—Russian
sk—Slovak
sl—Slovenian
sr—Serbian
sv—Swedish
th—Thai
tr—Turkish
uk—Ukrainian
vi—Vietnamese
zh-CN—Chinese (China)
zh-HK—Chinese (Hong Kong)
zh-TW—Chinese (Taiwan)

 

0 Kudos