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

How can I use an AutoComplete in a Create MVC view?

0 Answers 121 Views
AutoComplete
This is a migrated thread and some comments may be shown as answers.
Patrick
Top achievements
Rank 2
Patrick asked on 21 Jun 2012, 11:39 PM
I've been using the Telerik MVC extensions and want to be able to use an Autocomplete (but with the user able to enter something not in the dropdown list if he/she wants to) in a Create view.

Can I do this using the MVC extensions? If not can I do it using the Kendo UI MVC beta controls?

At the moment I have code like this in my view, but this doesn't allow the user to enter a value which is not in the dropdown list:

  <div class="editor-label">
            @Html.Label(model => model.PremiumPaymentFrequency)
        </div>
     <div class="editor-field">
            @Html.DropDownList("PremiumPaymentFrequency", String.Empty)
            @Html.ValidationMessageFor(model => model.PremiumPaymentFrequency)
        </div> 

The reason I ask for how to do this both using the Rad MVC extensions and the Kendo UI MVC controls is that although I want to start using Kendo UI MVC in new code, I would also like to know how to do it using the Rad MVC Telerik extensions in case I need to.
I need to be able to obtain the value entered by the user in the code.  With the RadMBC extensions, this is simply model.PremiumPaymentFrequency (which I can use in the controller code on the server), but how do I obtain the value entered by the user if a Kendo UI MVC control is used? (Is the value then only usable on the client, or can I use it in the server's controller code, and if so, how?).

Apologies if some of this seems basic, but I am obviously new to using the Kendo controls, particularly with MVC.

Thanks 

No answers yet. Maybe you can help?

Tags
AutoComplete
Asked by
Patrick
Top achievements
Rank 2
Share this question
or