Hello,
I am trying to understan how syncronization in data binding and afterwards the tracking of changed values works. Therefore I have 2 connected questions
Question 1 : In kendo ui documentation it says that "When the end-user changes the value of the DOM element (or widget) the bound View-Model value is updated. If the View-Model value is updated from code the value of the bound DOM element (or widget) is updated visually."I couldn't find how the second section (in bold) works.
I tried to writedevicenoValue = "444444";
to check if the DOM element is changing but it didn't work. How can I change it from the javascript side (ofcourse without the standart jquery option)
html code is :
<li>
<label>Device No
<input type="text" value="" id="device_no" data-value-update="keyup" data-bind="value: devicenoValue"/>
</label>
</li>
JS code is :
var settings = kendo.observable({
devicenoValue: "444444"
});
kendo.bind($("#device_no"), settings);
Question 2 : I need to know which element was changed in the DOM. How can I find this? I tried data-value-update="keyup" but couldn't findout how to use it for this purpose
I am trying to understan how syncronization in data binding and afterwards the tracking of changed values works. Therefore I have 2 connected questions
Question 1 : In kendo ui documentation it says that "When the end-user changes the value of the DOM element (or widget) the bound View-Model value is updated. If the View-Model value is updated from code the value of the bound DOM element (or widget) is updated visually."I couldn't find how the second section (in bold) works.
I tried to writedevicenoValue = "444444";
to check if the DOM element is changing but it didn't work. How can I change it from the javascript side (ofcourse without the standart jquery option)
html code is :
<li>
<label>Device No
<input type="text" value="" id="device_no" data-value-update="keyup" data-bind="value: devicenoValue"/>
</label>
</li>
JS code is :
var settings = kendo.observable({
devicenoValue: "444444"
});
kendo.bind($("#device_no"), settings);
Question 2 : I need to know which element was changed in the DOM. How can I find this? I tried data-value-update="keyup" but couldn't findout how to use it for this purpose