RadSearchbox

4 posts, 0 answers
  1. Pravallika
    Pravallika avatar
    30 posts
    Member since:
    Mar 2014

    Posted 13 Jun 2014 Link to this post

    Hai,

    i got one problem in radsearcchbox when i select any item in search box OnSearch event will rise and some dropdowns will bind based on Radsearchbox item now i got one problem when i remove that item in Radsearchbox i want to remove all the items in dropdowns 
    <cc1:RadSearchBox  runat="server" ID="cmbItemMaster" OnClientDataRequesting="OnClientSearch"
                                           OnSearch="cmbItemMaster_Search" Skin="WebBlue" Style="padding-right: 5px; padding-left: 5px; font-family: Calibri;"
                                                   Width="85%" AutoPostBack="true" ZIndex="10000000" DropDownSettings-Width="200px" DropDownSettings-Height="200px">
                                               </cc1:RadSearchBox>
    protected void cmbItemMaster_Search(object sender, SearchBoxEventArgs e)
            {
              
                    ddlMaterialCode.Items.Clear();
                    LoadMaterialCodes(e.Value);
                   
                }


    when i remove the selected item in radsearchbox the ddlMaterialCode will not show means the dropdown items of ddlMaterialCode is empty and after seleccting radsearchbox item then only it will bind how to do it sir
  2. Boyan Dimitrov
    Admin
    Boyan Dimitrov avatar
    1746 posts

    Posted 17 Jun 2014 Link to this post

    Hello,

    In this case I would suggest using the jQuery keyup event for the RadSearchBox input element and perform some logic once the text value of this element is empty. This means that the user has deleted the selected item text from the input field.
    //JavaScript
    function pageLoad() {
        $telerik.$(".rsbInput ").keyup(function () {
            //your logic for clearing the drop down items goes here
        });
    }


    Regards,
    Boyan Dimitrov
    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
  4. segolene
    segolene avatar
    3 posts
    Member since:
    Sep 2016

    Posted 12 Sep Link to this post

    Hello !

    I use a RadSearchBox like this : http://demos.telerik.com/aspnet-ajax/searchbox/examples/overview/defaultcs.aspx.

    And I search to have my result in First or a "auto-scroll" to go to my result.

    I tried with onFocus and this code :  var typeSearchBox = $find("<%= RadSearchBox1.ClientID %>");
                                                              typeSearchBox = typeSearchBox.get_inputElement();
                                                               typeSearchBox.focus();

     

    But I don't arrive. Do you have a idea ?

  5. Peter Milchev
    Admin
    Peter Milchev avatar
    139 posts

    Posted 15 Sep Link to this post

    Hello Segolene,

    There is already an answer to your question in your other thread: RadSearchBox and scrolling to go to the result. I would like to suggest you to continue the discussion there to avoid any duplication. 

    In general, for questions that are not related to the thread's original topic and scenario, we recommend opening a new thread. This will facilitate a tidier support history of your account and better support service.

    Regards,
    Peter Milchev
    Telerik by Progress
    Do you need help with upgrading your ASP.NET AJAX, WPF or WinForms projects? Check the Telerik API Analyzer and share your thoughts.
Back to Top