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

Multiple bindings on data-bind

4 Answers 880 Views
MVVM
This is a migrated thread and some comments may be shown as answers.
Chris
Top achievements
Rank 1
Chris asked on 30 Mar 2012, 09:56 AM
Another question for you lovely Kendo people!

I'm currently struggling to bind more than one function to a Grid, my code is:

<div id="grid" data-role="grid" data-bind="source: gridSource"></div>

Which works fine, but I want this Grid to be a multi-selectable Grid (my own Kendo extension) and can't seem to bind this when I try:

<div id="grid" data-role="grid" data-bind="source: gridSource, selectableGrid: selectOptions"></div>

The error displays as "selectableGrid" is not supported by "div" or something along those lines. However, if I try and just use the selectableGrid without the source binding, then it works fine.

Any suggestions, or will this be fixed in a future release?

4 Answers, 1 is accepted

Sort by
0
Atanas Korchev
Telerik team
answered on 30 Mar 2012, 10:19 AM
Hi,

 We can't really say anything without seeing the code first.

All the best,
Atanas Korchev
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
Chris
Top achievements
Rank 1
answered on 30 Mar 2012, 02:46 PM
This is a demo of the failing scenario: http://jsfiddle.net/Xxn22/3/
I've worked with Knockout a lot, and this is where I'm basing my concepts from.
0
Accepted
Atanas Korchev
Telerik team
answered on 30 Mar 2012, 03:02 PM
Hello,

 Custom widget binders are special :) They live in another namespace. Here is the updated jsfiddle: http://jsfiddle.net/korchev/Xxn22/4/ 

 Also make sure you call kendo.bind *after* registering the custom binder.

Regards,
Atanas Korchev
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
Chris
Top achievements
Rank 1
answered on 30 Mar 2012, 03:08 PM
Amazing, thank you, again! Things like this are giving me a whole lot more confidence in the MVVM side of Kendo, your patience with all my questions is very much appreciated :)
Tags
MVVM
Asked by
Chris
Top achievements
Rank 1
Answers by
Atanas Korchev
Telerik team
Chris
Top achievements
Rank 1
Share this question
or