
| <form id="form1" runat="server"> |
| <telerik:RadScriptManager ID="RadScriptManager1" runat="server"> |
| </telerik:RadScriptManager> |
| <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server"> |
| <AjaxSettings> |
| <telerik:AjaxSetting AjaxControlID="Panel1"> |
| <UpdatedControls> |
| <telerik:AjaxUpdatedControl ControlID="Panel1" LoadingPanelID="RadAjaxLoadingPanel1" /> |
| </UpdatedControls> |
| </telerik:AjaxSetting> |
| </AjaxSettings> |
| </telerik:RadAjaxManager> |
| <div> |
| <asp:Panel ID="Panel1" runat="server" Width="100%" Height="100%"> |
| <uc1:WebUserControl ID="WebUserControl1" runat="server"/> |
| <asp:Label ID="Label1" runat="server" Text="Label"></asp:Label> |
| </asp:Panel> |
| <telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" Height="100%" |
| Width="100%"> |
| <img alt="Loading..." src='<%= RadAjaxLoadingPanel.GetWebResourceUrl(Page, "Telerik.Web.UI.Skins.Default.Ajax.loading.gif") %>' |
| style="border: 0px;" /> |
| </telerik:RadAjaxLoadingPanel> |
| </div> |
| </form> |
| <div> |
| <telerik:RadAjaxManagerProxy ID="RadAjaxManagerProxy1" runat="server"> |
| <AjaxSettings> |
| <telerik:AjaxSetting AjaxControlID="Button1"> |
| <UpdatedControls> |
| <telerik:AjaxUpdatedControl ControlID="RadComboBox2" LoadingPanelID="RadAjaxLoadingPanel1" /> |
| </UpdatedControls> |
| </telerik:AjaxSetting> |
| </AjaxSettings> |
| </telerik:RadAjaxManagerProxy> |
| <div> |
| <table> |
| <tr> |
| <td> |
| <telerik:RadComboBox ID="RadComboBox1" runat="server"> |
| <ItemTemplate> |
| <asp:CheckBox ID="chkbxSalesRep" runat="server" EnableViewState="true" Text="abc" /> |
| </ItemTemplate> |
| <CollapseAnimation Duration="200" Type="OutQuint" /> |
| <FooterTemplate> |
| <table> |
| <tr> |
| <td> |
| <asp:Button ID="Button1" runat="server" Text="Button" OnClick="Button1_Click" /></td> |
| </tr> |
| </table> |
| </FooterTemplate> |
| </telerik:RadComboBox> |
| </td> |
| <td> |
| <telerik:RadComboBox ID="RadComboBox2" runat="server"> |
| <ItemTemplate> |
| <asp:CheckBox ID="chkbxSalesRep" runat="server" EnableViewState="true" Text="abc" /> |
| </ItemTemplate> |
| <CollapseAnimation Duration="200" Type="OutQuint" /> |
| <Items> |
| <telerik:RadComboBoxItem runat="server" Text="RadComboBoxItem1" Value="RadComboBoxItem1" /> |
| <telerik:RadComboBoxItem runat="server" Text="RadComboBoxItem2" Value="RadComboBoxItem2" /> |
| <telerik:RadComboBoxItem runat="server" Text="RadComboBoxItem3" Value="RadComboBoxItem3" /> |
| <telerik:RadComboBoxItem runat="server" Text="RadComboBoxItem4" Value="RadComboBoxItem4" /> |
| <telerik:RadComboBoxItem runat="server" Text="RadComboBoxItem5" Value="RadComboBoxItem5" /> |
| <telerik:RadComboBoxItem runat="server" Text="RadComboBoxItem6" Value="RadComboBoxItem6" /> |
| </Items> |
| </telerik:RadComboBox> |
| </td> |
| </tr> |
| <tr> |
| <td colspan="2"><asp:Button ID="Button2" runat="server" Text="Button" OnClick="Button2_Click" /></td> |
| </tr> |
| </table> |
| </div> |
| <telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" Height="100%" |
| Width="100%"> |
| <img alt="Loading..." src='<%= RadAjaxLoadingPanel.GetWebResourceUrl(Page, "Telerik.Web.UI.Skins.Default.Ajax.loading.gif") %>' |
| style="border: 0px;" /> |
| </telerik:RadAjaxLoadingPanel> |
| </div> |
| // web user control |
| public partial class WebUserControl : System.Web.UI.UserControl |
| { |
| protected void Page_Load(object sender, EventArgs e) |
| { |
| } |
| protected void Button1_Click(object sender, EventArgs e) |
| { |
| } |
| protected void Button2_Click(object sender, EventArgs e) |
| { |
| } |
| } |
| // the page |
| public partial class _Default : System.Web.UI.Page |
| { |
| protected void Page_Load(object sender, EventArgs e) |
| { |
| } |
| } |

Here is my rad grid:
| <radT:RadGrid ID="table" Skin="WebBlue" GridLines="Both" AllowPaging="true" |
| EnableEmbeddedSkins="false" OnPreRender="HighlightRows" PageSize="15" runat="server"> |
| <MasterTableView Width="100%" ClientDataKeyNames="ID,Question" ></MasterTableView> |
| <PagerStyle Mode="NextPrevAndNumeric" PagerTextFormat="Change page: {4} | Displaying page {0} of {1}, questions {2} to {3} of {5}" > |
| </PagerStyle> |
| <ClientSettings> |
| <Selecting AllowRowSelect="True" /> |
| <ClientEvents OnRowContextMenu="RowContextMenu" OnRowSelected="ModifyHeader" OnRowMouseOver="test" /> |
| </ClientSettings> |
| </radT:RadGrid> |
| <radT:RadToolTipManager ID="RadToolTipManager1" runat="server" OnAjaxUpdate="RadToolTipManager1_AjaxUpdate" |
| RelativeTo="Mouse" Position="BottomLeft" AutoTooltipify="false" |
| Title="Question Preview" ManualClose="true" ShowEvent="OnClick"> |
| </radT:RadToolTipManager> |
My first problem is that I could not get it to work with individual rows here is how i added the rows in the code behind:
| foreach (Telerik.Web.UI.GridDataItem gdi in table.Items) |
| { |
| RadToolTipManager1.TargetControls.Add(gdi.ClientID, true); |
| } |
with this setup the . OnAjaxUpdate event does not fire.
I then tried just adding the whole rad grid to the tooltip manager with this:
<TargetControls><radT:ToolTipTargetControl TargetControlID="table" /></TargetControls>
The problem I had with this is that the OnAjaxUpdate event only fires and the tooltip shows after the table first does an event that causes a postback such as if I change the page index or have ClientSettings-EnablePostBackOnRowClick enabled and do a postback.
Can anyone tell me what I am doing wrong? I do not think I have the latest versions of the controls (I think I have RadControls for ASPNET AJAX Q1 2008), and will have to contact someone else apout updateing. Is this caused from a bug in the control or something I am doing wrong?
| Me.EnableEmbeddedSkins = False |
| Me.Animation = Telerik.Web.UI.ToolTipAnimation.None |
| Me.ContentScrolling = Telerik.Web.UI.ToolTipScrolling.None |
| Me.HideDelay = 5000 |
| Me.Position = Telerik.Web.UI.ToolTipPosition.BottomRight |
| Me.RelativeTo = Telerik.Web.UI.ToolTipRelativeDisplay.Element |
| Me.ShowDelay = 350 |
| Me.ShowCallout = False |
| Me.Sticky = True |
| Me.HideEvent = Telerik.Web.UI.ToolTipHideEvent.LeaveToolTip |
| Me.OnClientBeforeShow = "Tooltip_OnBeforeShow" |
| Client-side: |
| function Tooltip_OnBeforeShow(sender, eventArgs) { |
| var intPosition, intWidth, intHeight; |
| intHeight = document.body.offsetHeight; |
| intWidth = document.body.offsetWidth; |
| if (sender._mouseY <= (intHeight / 3)) |
| { |
| intPosition = 30; |
| } |
| else if ((sender._mouseY <= (intHeight / 3) * 2)) |
| { |
| intPosition = 20; |
| } |
| else if ((sender._mouseY > (intHeight / 3) * 2)) |
| { |
| intPosition = 10; |
| } |
| if (sender._mouseX <= (intWidth / 2)) |
| { |
| intPosition += 3; |
| } |
| else if (sender._mouseX > (intWidth / 2)) |
| { |
| intPosition += 1; |
| } |
| sender.set_position(intPosition); |
| } |
| <form id="form1" runat="server"> |
| <telerik:RadScriptManager ID="RadScriptManager1" runat="server"> |
| </telerik:RadScriptManager> |
| <telerik:RadFormDecorator ID="RadFormDecorator1" runat="server" /> |
| <div> |
| <table class="myTable"> |
| <!-- Date & Time Call Received --> |
| <tr> |
| <th class="inputLabel"> |
| <asp:Label ID="lblCallReceivedDate" CssClass="inputLabel" runat="server" Text="Call received:" |
| ToolTip="Date and time the call was received"></asp:Label> |
| </th> |
| <td class="input"> |
| <telerik:RadDateTimePicker ID="dpCallReceived" runat="server" Skin="Office2007" ToolTip="Date and time the call was received"> |
| <TimePopupButton HoverImageUrl="" ImageUrl="" /> |
| <TimeView CellSpacing="-1" Culture="English (United Kingdom)"> |
| </TimeView> |
| <Calendar Skin="Office2007" UseColumnHeadersAsSelectors="False" UseRowHeadersAsSelectors="False" |
| ViewSelectorText="x"> |
| </Calendar> |
| <DatePopupButton HoverImageUrl="" ImageUrl="" /> |
| </telerik:RadDateTimePicker> |
| </td> |
| </tr> |
| <!-- Received from (Stakeholder) --> |
| <tr> |
| <th class="inputLabel"> |
| <asp:Label ID="lblAnonymous" CssClass="inputLabel" runat="server" Text="Anonymous:" |
| ToolTip="Check this box if caller's identity is unknown"></asp:Label> |
| </th> |
| <td class="input"> |
| <asp:CheckBox ID="chkAnonymous" runat="server" ToolTip="Check this box if caller's identity is unknown" |
| Text=" " /> |
| </td> |
| </tr> |
| <tr> |
| <th class="inputLabel"> |
| <asp:Label ID="lblCaller" CssClass="inputLabel" runat="server" Text="Caller:" ToolTip="Person/organisation who reported the incident"></asp:Label> |
| </th> |
| <td class="input"> |
| <asp:Label ID="lblAnon" runat="server" Text="Anonymous"></asp:Label> |
| </td> |
| </tr> |
| </table> |
| </div> |
| </form> |