myCalendar loadUserLanguage is not a function

I copied this example dhtmlx.com/docs/products/dht … guage.html

And I got “TypeError: myCalendar.loadUserLanguage is not a function”

<!DOCTYPE html>
<html>
<head>
	<meta charset="utf-8" />
	<title>Calendar</title>
	<link rel="stylesheet" type="text/css" href="http://www.dhtmlx.com/docs/products/dhtmlxCalendar/codebase/dhtmlxcalendar.css">
    <link rel="stylesheet" type="text/css" href="http://www.dhtmlx.com/docs/products/dhtmlxCalendar/codebase/skins/dhtmlxcalendar_dhx_skyblue.css">
	<script src="http://www.dhtmlx.com/docs/products/dhtmlxCalendar/codebase/dhtmlxcommon.js"></script>
<script src="http://www.dhtmlx.com/docs/products/dhtmlxCalendar/codebase/dhtmlxcalendar.js"></script>
<script src="http://www.dhtmlx.com/docs/products/dhtmlxCalendar/codebase/ext/dhtmlxcalendar_double.js"></script>
</head>
<script>
dhtmlXCalendarObject.prototype.langData["de"] = {
    dateformat: '%d.%m.%Y',
    monthesFNames: ["Januar", "Februar", "März", "April", "Mai", "Juni", "Juli", "August", "September", "Oktober", "November", "Dezember"],
    monthesSNames: ["Jan", "Feb", "Mär", "Apr", "Mai", "Jun", "Jul", "Aug", "Sep", "Okt", "Nov", "Dez"],
    daysFNames: ["Sonntag", "Montag", "Dienstag", "Mittwoch", "Donnerstag", "Freitag", "Samstag"],
    daysSNames: ["So", "Mo", "Di", "Mi", "Do", "Fr", "Sa"],
    weekstart: 1
}
dhtmlXCalendarObject.prototype.langData["ru"] = {
    dateformat: '%d.%m.%Y',
    monthesFNames: ["Январь", "Февраль", "Март", "Апрель", "Май", "Июнь", "Июль", "Август", "Сентябрь", "Октябрь", "Ноябрь", "Декабрь"],
    monthesSNames: ["Янв", "Фев", "Мар", "Апр", "Май", "Июн", "Июл", "Авг", "Сен", "Окт", "Ноя", "Дек"],
    daysFNames: ["Воскресенье", "Понедельник", "Вторник", "Среда", "Четверг", "Пятница", "Суббота"],
    daysSNames: ["Вс", "Пн", "Вт", "Ср", "Чт", "Пт", "Сб"],
    weekstart: 1
}
 
var myCalendar;
function doOnLoad() {
    myCalendar = new dhtmlXCalendarObject("calendarHere");
    myCalendar.setDate(new Date(2013, 2, 1, 16, 0));
    myCalendar.show();
}

</script>
<body onload="doOnLoad();">
	<div style="margin-bottom: 20px;">
        <input type="button" value="en" onclick="myCalendar.loadUserLanguage('en');">
        <input type="button" value="de" onclick="myCalendar.loadUserLanguage('de');">
        <input type="button" value="ru" onclick="myCalendar.loadUserLanguage('ru');">
    </div>
    <div id="calendarHere" style="position:relative;height:250px;"></div>
</body>
</html>

Hi

please provide direct link or completed demo including all corresponding js/css files

Take
plnkr.co/edit/DPOjfV0dxqanUHKntvpW?p=preview
It must work ‘all-in-one’

that’s because for demos obfuscated version is used. you need to download calendar package from site and it will ok, do not use js from site

Can I use JSON and Angular to set language?
ex.
dhtmlXCalendarObject.prototype.langData[ {{language}} ] = json_obj;

I don’t need dhtmlXCalendarObject.prototype.langData[“de”] = {…} in JS

I have myCalendar.loadUserLanguage(value). I use Angular to set ‘value’.

My lang.json :

{ "mylang": { "dateformat": "%d.%M.%Y", "monthesFNames": [ "Jan...", "Dec..." ], "monthesSNames": [ "Jan", "Dec" ], "daysFNames": [ "Su...", "Sa..." ], "daysSNames": [ "Su", "Sa" ], "weekstart": "1", "weekname": "w" } }