Ajax tooltip with asp:button

2 posts, 0 answers
  1. Michael Tissington
    Michael Tissington avatar
    64 posts
    Member since:
    Nov 2007

    Posted 19 Nov 2007 Link to this post

    I have an asp:button with an OnCommand event.

    In the code behind I'd like to Validate the page and return either the tooltip (and show it) or do some other processing.

    How do I go about returning the tooltip and showing it ?

  2. Tsvetie
    Tsvetie avatar
    1517 posts

    Posted 20 Nov 2007 Link to this post

    Hello Michael Tissington,
    Please have a look at the following code fragment that demonstrates one possible approach:

        <script type="text/javascript">  
        function OpenToolTip()  
        function ShowToolTip()  
            var tooltip = $find('<%= RadToolTip1.ClientID %>');  
        <form id="form1" runat="server">  
            <asp:ScriptManager ID="ScriptManager1" runat="server" /> 
            <telerik:RadToolTip ID="RadToolTip1" runat="server" TargetControlID="Button1"   
                RelativeTo="Element" ShowEvent="OnRightClick">  
            <asp:Button ID="Button1" runat="server" Text="ShowToolTip" OnClick="Button1_Click" /> 

    protected void Button1_Click(object sender, EventArgs e)  
        if (Button1.Text == "ShowToolTip")  
            Button1.Text = "Second";  

    All the best,
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
Back to Top