Select an item from Javascript

2 posts, 0 answers
  1. ghini
    ghini avatar
    25 posts
    Member since:
    Sep 2012

    Posted 08 Jan 2015 Link to this post

    Hello everyone,
    I'm working with radAutoCompleteBox.
    Is there a way to select an item from Javascript?

    Thanks
  2. Aneliya Petkova
    Admin
    Aneliya Petkova avatar
    207 posts

    Posted 09 Jan 2015 Link to this post

    Hi ghini,

    You can add an entry in the RadAutoCompleteBox using the Client-Side API.
    For example:
    function addNewEntry(sender, args) {
        var autoCompleteBox = $find("<%= RadAutoCompleteBox1.ClientID %>");
        var textBox = $find("RadTextBox1");
        if (textBox.get_value() == "") return;
        var entry = new Telerik.Web.UI.AutoCompleteBoxEntry();
        entry.set_text(textBox.get_value());
        autoCompleteBox.get_entries().add(entry);
    }

    If this is not what you are looking for, could you please explain in more details what is the exact functionality you want to achieve(perhaps you can give us an example)?

    Regards,
    Aneliya Petkova
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
  3. UI for ASP.NET Ajax is Ready for VS 2017
Back to Top