Ok so i am using SiteFinity and playing with the RadToolTipManager. Because this is SiteFinity, my RadToolTipManager is inside a UserControl. That said i am trying to dynamically load the UserControl for the RadToolTipManager from this UserControl... Now that i have confused everyone sufficients, i am also trying to access properties within the RadToolTipManager Control i am loading Dynamically. I am frustrated cause none of the example on the Telerik site show the code behind of the user control.
I need help and i need help BAD...
So here are the details:
Results.ascx.cs
On an ItemDatabound mothd i add the control to the RadToolTipManager
As per the examples the code behind here has the following methods which the RadToolTipManager calles:
Notice above i have commented out the lines where the property on the loaded control is accesses as i do not know how ProductDetails is inherited down and there is no explaination of this anywhere... If it were part of the ASPX page i might be able to access it but in my case it is part of a ASCX UserControl and being loaded dynamically.
So here is my UserControl i am trying to LoadOnDemand
FlightInformation.ascx.cs
Can someone please help me load this control Dynamically and have access to it property from the OnAjaxUpdate method!
Thanks in advance,
Duncan
I need help and i need help BAD...
So here are the details:
Results.ascx.cs
On an ItemDatabound mothd i add the control to the RadToolTipManager
RadToolTipManager1.TargetControls.Add(((Label)rpti.FindControl("lblFlightNum")).ClientID, "", true); |
As per the examples the code behind here has the following methods which the RadToolTipManager calles:
protected void OnAjaxUpdate(object sender, ToolTipUpdateEventArgs args) |
{ |
this.UpdateToolTip(args.Value, args.UpdatePanel); |
} |
private void UpdateToolTip(string elementID, UpdatePanel panel) |
{ |
Control ctrl = Page.LoadControl("~/UserControls/PFV_3.0_TooltipControls/FlightInformation.ascx"); |
panel.ContentTemplateContainer.Controls.Add(ctrl); |
//ProductDetails details = (ProductDetails)ctrl; |
//details.ProductID = elementID; |
} |
Notice above i have commented out the lines where the property on the loaded control is accesses as i do not know how ProductDetails is inherited down and there is no explaination of this anywhere... If it were part of the ASPX page i might be able to access it but in my case it is part of a ASCX UserControl and being loaded dynamically.
So here is my UserControl i am trying to LoadOnDemand
FlightInformation.ascx.cs
using System; |
using System.Data; |
using System.Configuration; |
using System.Collections; |
using System.Web; |
using System.Web.Security; |
using System.Web.UI; |
using System.Web.UI.WebControls; |
using System.Web.UI.WebControls.WebParts; |
using System.Web.UI.HtmlControls; |
public partial class UserControls_TooltipControls_FlightInformation : System.Web.UI.UserControl |
{ |
string ParameterArray; |
public virtual string Parameters |
{ |
get |
{ |
return ParameterArray; |
} |
set |
{ |
ParameterArray = value; |
} |
} |
protected void Page_Load(object sender, EventArgs e) |
{ |
} |
} |
Can someone please help me load this control Dynamically and have access to it property from the OnAjaxUpdate method!
Thanks in advance,
Duncan