RadComboBox + RadTooltip for no items found

4 posts, 0 answers
  1. Alan T
    Alan T avatar
    125 posts
    Member since:
    Apr 2010

    Posted 12 Mar 2012 Link to this post

    Hi, 

    I'm struggling to implement this, i'm not sure why.

    I've got a RadComboBox, and i've manually implemented the onitemsrequested event of it, to enable custom loading on demand.

    I've then attached my tooltip. Both of which are inside an asp:Panel which is ajaxified using the RadAjaxManager.

    <telerik:RadToolTip ID="tt_searchArea_empty" runat="server"
    TargetControlID="cbo_searchArea" HideEvent="FromCode" ShowEvent="FromCode" 
    RelativeTo="Element">
    </telerik:RadToolTip>

       

    and show it in code behind (search locations is my combobox's datasource).

       

    If search_locations.Count <= 0 Then
    Me.tt_searchArea_empty.Text = "Could not find any results for """ & e.Text & ""
    Me.tt_searchArea_empty.Show()
    End If

    And to hide it, i've attached this client side event OnFocus of my combobox:

    var tt = '<%=tt_searchArea_empty.ClientID %>';
    tt.hide();
  2. Kevin
    Kevin avatar
    360 posts
    Member since:
    Jul 2012

    Posted 12 Mar 2012 Link to this post

    Hello Alan,

    I'm assuming the show part must work. The problem I see with your js code is that you're not using the $find method to grab the instance of the RadTooltip. You js code should look like this:

    var tt = $find('<%=tt_searchArea_empty.ClientID %>');
    tt.hide();
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Alan T
    Alan T avatar
    125 posts
    Member since:
    Apr 2010

    Posted 12 Mar 2012 Link to this post

    no, the show part is unfortunately not working.

    I'm not sure why, that line of code is definately executing. Perhaps its something to do with it being in an ajaxified panel?

    My AjaxManager defintiino is basically:

        <telerik:RadAjaxManager ID="ram_home" runat="server" DefaultLoadingPanelID="ralp_front">
            <AjaxSettings>
                <telerik:AjaxSetting AjaxControlID="pnl_searchBox">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="pnl_searchBox" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
            </AjaxSettings>
        </telerik:RadAjaxManager>

    where all controls mentioned are inside pnl_searchBox.
  5. Alan T
    Alan T avatar
    125 posts
    Member since:
    Apr 2010

    Posted 13 Mar 2012 Link to this post

    I ended up doing this via client side methods instead. 

    Can be closed. 

Back to Top