This is a migrated thread and some comments may be shown as answers.

databinding in templates not working

0 Answers 38 Views
MVVM
This is a migrated thread and some comments may be shown as answers.
david
Top achievements
Rank 1
david asked on 04 Jul 2012, 09:10 AM
Hi 

if I create kendoGrid like this:

$('#grid').kendoGrid({
            dataSource: {
                data: [{Name: 'Alex', Age: 44}, {Name:'David', Age: 13}]
             },
            rowTemplate: kendo.template($('#row-template').html()),
        });


the template looks this:
 <script id="row-template" type="text/x-kendo-template">
        <tr class="k-grid-edit-row" ">
            <td>
                <input data-bind="value: Name"/>
            </td>
            <td>
                <inputd ata-bind="value: Age"/>
            </td>
        </tr>
    </script>

then I see the grid rendered correctly but the databinding is not working at all.

thanks

No answers yet. Maybe you can help?

Tags
MVVM
Asked by
david
Top achievements
Rank 1
Share this question
or