Jquery AutoComplete Using RadTextBox

2 posts, 0 answers
  1. Muhammad
    Muhammad avatar
    87 posts
    Member since:
    Oct 2012

    Posted 15 Mar 2012 Link to this post


    I am using Radtooltip and under that I have placed a RadText box control.

    Basically I want to use Jquery Autocomplete to fetch the data for my Radtextbox using wcf web service. The webservice returns that data but the problem is that I can't use autocomplete operation for my radtextbox because Jquery works on HTML element. Is there any client side function which I can use to get the html element Id of my radtextbox.

    <script type="text/javascript" src="js/jquery-1.7.1.min.js"></script>
    <script type="text/javascript">

        function GetJobs(sender, args) {

            var s = new PS.PSService();
            s.GetJobs(function (data) {
                    source: data,
                    minLength: 2


    telerik:RadToolTip ID="rttMore" runat="server" TargetControlID="tbSearch" EnableEmbeddedBaseStylesheet="true"
                                                                RelativeTo="Element" ShowCallout="true" HideDelay="4000" HideEvent="LeaveTargetAndToolTip"
                                                                Position="BottomCenter" Width="500px" Height="90px">
                                                                <fieldset id="fsMain" runat="server">
                                                                    <legend class="fieldsetLegend" id="fslgndMain" runat="server">Select Filter </legend>
                                                                    <asp:Panel ID="pnlSearch" runat="server" DefaultButton="btnGoSearchByJobName">
                                                                        Search by job <b>name / number</b>
                                                                        <telerik:RadTextBox ID="tbSearchByJobName" MaxLength="50" EmptyMessage="Leave empty for all jobs or enter a Job Name / Job No (Press Enter Key for search)"
                                                                            Width="430px" runat="server">
                                                                            <ClientEvents OnLoad="GetJobs" />
                                                                        <asp:RegularExpressionValidator ID="valSearch" runat="server" ForeColor="Red" Display="Dynamic"
                                                                            ErrorMessage="Please enter a valid Job Name / Job Number" ControlToValidate="tbSearchByJobName"
                                                                        <asp:Button ID="btnGoSearchByJobName" runat="server" Text="Go" OnClick="btnGoSearchByJobName_Click" />
                                                                        <br />
  2. Kevin
    Kevin avatar
    360 posts
    Member since:
    Jul 2012

    Posted 15 Mar 2012 Link to this post

    Hello Muhammad,

    To get the RadTextBox's input element, you use sender.get_element(). Also, the AutoComplete feature you're using could easily be done with the RadComboBox and LoadOnDemand, which can be linked to a WCF Web Service. You can also control the minimum amount of characters to type by the using the MinFilterLength property of the RadComboBox.

    Link to RadComboBox - WCF Service Demo:

    I hope that helps.
Back to Top