I am trying to use the MultiSelectFor without to much luck. I have
Posting the contents to the controller works correctly however when the view is loaded any "SelectedEmployeeIds" are not displayed.
Any help would be great.
Thank you
@Html.Kendo().MultiSelectFor(m => m.SelectedEmployeeIds).BindTo(Model.Employees).DataTextField("EmployeeName").DataValueField("EmployeeId").ItemTemplate("<
span
class
=
'span2'
>#: data.EmployeeName #</
span
><
span
><
strong
>#: data.Email #</
strong
></
span
>").Placeholder("Select Names")
Any help would be great.
Thank you
5 Answers, 1 is accepted
0
Hello Shane,
Georgi Krustev
the Telerik team
Here is a quote of my answer posted in the support ticket opened on the same subject:
The problem is related to a limitation in the MultiSelect for ASP.NET MVC, which can be bound only to List<string> instance. This is addressed in the latest internal build of Kendo UI.
Georgi Krustev
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
Jonathan
Top achievements
Rank 1
answered on 26 Apr 2013, 11:21 AM
Hi Georgi,
I've updated my project using visual studio (menu telerik -> kendo -> upgrade)
But this is not working ...
Here is the code in MVC Controller:
Here is the code in the CSTHML file
I've got the following error:
The best overloaded method match for
'Kendo.Mvc.UI.Fluent.MultiSelectBuilder.Value(System.Collections.Generic.IEnumerable<string>)'
has some invalid arguments
Can you please help?
Thank you
I've updated my project using visual studio (menu telerik -> kendo -> upgrade)
But this is not working ...
Here is the code in MVC Controller:
ViewBag.AccomodationBOFees = new SelectList(db.Fees.Where(f => f.FEETOFID == EITWEP.Utils.WEPConstants.FeeConstant.AccomodationTypeOfFeeID).OrderBy(f => f.FEETitle), "FEEID", "FEETitle");
SelectList selectedBOFees = new SelectList(db.Fees.Where(f=> f.FEEID == 565), "FEEID", "FEETitle");
@(Html.Kendo().MultiSelect().Value(ViewBag.selectedBOFees)
.Name("RelatedFees").HtmlAttributes(new { style = "width: 500px;" }).BindTo(ViewBag.AccomodationBOFees).Filter("contains").MinLength(2)
)
The best overloaded method match for
'Kendo.Mvc.UI.Fluent.MultiSelectBuilder.Value(System.Collections.Generic.IEnumerable<string>)'
has some invalid arguments
Can you please help?
Thank you
0
Hello Jonathan,
Georgi Krustev
the Telerik team
The aforementioned issue is fixed in the last internal build, which is available only for paid customers. Note also that the Visual Studio update cannot not update your project to use latest internal build.
Georgi Krustev
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
Info Expert-IT
Top achievements
Rank 1
answered on 02 May 2013, 09:15 AM
Hi,
We've bougth our licence and there is no error anymore but the selected values are not shown in the multiselect...
I've posted a ticket in the support.
Best regards,
We've bougth our licence and there is no error anymore but the selected values are not shown in the multiselect...
I've posted a ticket in the support.
Best regards,
0
Hello,
Georgi Krustev
the Telerik team
As I pointed in the support thread, you will need to update javascript files, css files and the DDL. Check this help topic for more information.
Georgi Krustev
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!