Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
200 views
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
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


InfySam
Top achievements
Rank 1
 answered on 10 May 2012
7 answers
261 views
Hello
I'm facing an intersting issue

I want to select an item in a paged listview when the page is displayed.
The selected item key is stored in session

How can I achieve that?

Thanks and regards
Philippe


Jason Horspool
Top achievements
Rank 1
 answered on 10 May 2012
2 answers
116 views
Ever since we have installed newest Telerik release 2012 (Q1 sp1), I've started to notice one issue with page navigation for RadGrid.
I have provided three images to illustrate my point. Screen shot one and two everything is working properly  page navigation works fine, but when I am trying to click button 3 (screen shot 3)  grid does not navigate to third page and remains on a second page with buttons 1 and 2  selected. If I click once more on button 3, grid displays page 3 and the pattern repeats for all the other pages.

This particular grid is a bit unique it is totally dynamic and is build in code using column templates to handle variable number of columns and also to allow count and sum in a single column.

All other grids work as expected in latest release. Previous release 2011 Q3 Sp1 paging was working fine for all our grids.

Thanks
Pavlina
Telerik team
 answered on 10 May 2012
5 answers
110 views
Hi,

When we try the newer dll's (version 2012.1.215.40) we are facing problems, the grid's are getting messed up as shown in screenshot.
The older version 2010.2.826.35 works fine.

What is the fix for this?

Attached is the screenshot.
Pavlina
Telerik team
 answered on 10 May 2012
0 answers
83 views
Hello,
           var strClientID = getClientID(obj.id, "chkSelectAll") + "RgGridCt";
            var stClientRi = getClientID(obj.id, "chkSelectAll") + "RgGridR";
            var strClientRe = getClientID(obj.id, "chkSelectAll") + "rgGridRe";
       
    tableView = $find(strClientID).get_masterTableView();

In the above code, if the grid is not rgGridCt, tableview is throwing error.

In my page, I am having 3 different grids. If I select one of them, how can I pass the correct value so that tableview will not throw error.

TIA
Atchut
Top achievements
Rank 1
 asked on 10 May 2012
3 answers
127 views
I've been tasked with applying a loading panel over a RadGrid that is nested in an UpdatePanel. I placed a RadAjaxManager and a RadAjaxLoadingPanel inside the update definition. The loading panel works, but for some reason, the paging on the RadGrid breaks, and it alternates between doing a full page refresh and a proper AJAX request. I've tried to replace the UpdatePanel with a RadAjaxPanel, but that didn't fix the problem, and in fact started mangling the RadGrid display.
Here's the code that's causing the problem. Any info would be appreciated. Thanks!

<asp:UpdatePanel ID="UpdatePanel1" runat="server" UpdateMode="Always">
       <ContentTemplate>
            <radG:RadAjaxManager ID="RadAjaxManager1" runat="server">
               <AjaxSettings>
                   <radG:AjaxSetting AjaxControlID="btnSearch">
                       <UpdatedControls>
                           <radG:AjaxUpdatedControl ControlID="UpdatePanel1" LoadingPanelID="RadAjaxLoadingPanel1" />
                       </UpdatedControls>
                   </radG:AjaxSetting>
               </AjaxSettings>
          </radG:RadAjaxManager>
          <radG:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" Skin="Office2007" >
          </radG:RadAjaxLoadingPanel>
           
             <radG:RadGrid ID="grdCampaignStatus" runat="server" PageSize="50" Width="100%" Height="565px" Skin="Office2007"
               EnableEmbeddedSkins="true" GridLines="None" AllowPaging="true" AutoGenerateColumns="False"
               AllowSorting="true" ShowGroupPanel="False" StatusBarSettings-ReadyText="Ready"
               StatusBarSettings-LoadingText="Please Wait..." ShowStatusBar="True">
               <ClientSettings AllowDragToGroup="True">
                   <Resizing AllowColumnResize="True" EnableRealTimeResize="True" ResizeGridOnColumnResize="True">
                   </Resizing>
                   <Scrolling AllowScroll="True" UseStaticHeaders="True"></Scrolling>
               </ClientSettings>
               <MasterTableView AllowNaturalSort="false" TableLayout="Fixed">
                   <Columns>
                       <radG:GridBoundColumn SortExpression="Campaign Id" AllowSorting="True" HeaderText="Campaign Id"
                           DataField="[Campaign Id]">
                       </radG:GridBoundColumn>
                       <radG:GridBoundColumn HeaderText="Campaign Name" AllowSorting="true" SortExpression="Campaign Name" DataField="[Campaign Name]">
                       </radG:GridBoundColumn>
                       <radG:GridBoundColumn HeaderText="Status" AllowSorting="true" SortExpression="Status" DataField="[Status]">
                       </radG:GridBoundColumn>
                       <radG:GridBoundColumn HeaderText="Placed Date" AllowSorting="true" SortExpression="Placed Date" DataField="[Placed Date]">
                       </radG:GridBoundColumn>
                       <radG:GridBoundColumn HeaderText="Requested launch Date/Time" AllowSorting="true" SortExpression="Requested Launch" DataField="[Requested Launch]">
                       </radG:GridBoundColumn>
                       <radG:GridBoundColumn HeaderText="Date/Time sent" AllowSorting="true" SortExpression="Time Sent" DataField="[Time Sent]">
                       </radG:GridBoundColumn>
                       <radG:GridBoundColumn HeaderText="First Name" AllowSorting="true" SortExpression="First Name" DataField="[First Name]">
                       </radG:GridBoundColumn>
                       <radG:GridBoundColumn HeaderText="Last Name" AllowSorting="true" SortExpression="Last Name" DataField="[Last Name]">
                       </radG:GridBoundColumn>
                       <radG:GridBoundColumn HeaderText="Reply To" AllowSorting="true" SortExpression="Reply To" DataField="[Reply To]">
                       </radG:GridBoundColumn>
                       <radG:GridBoundColumn HeaderText="Recipient Count" AllowSorting="true" HeaderStyle-Width="50" SortExpression="Recipient Count" DataField="[Recipient Count]">
                       </radG:GridBoundColumn>
                       
                       <radG:GridTemplateColumn HeaderText="Run" UniqueName="TemplateColumn" HeaderStyle-Width="30">
                           <ItemTemplate>
                               <asp:Button ID="LinkButtonRedistribute"    CommandName="ExecuteService" OnClientClick = "return confirm('Do you want to run the campaign service?');"  
                                   CommandArgument='<%# DataBinder.Eval(Container.DataItem,"[Campaign Id]") %>' runat="server"
                                   Text="Run"></asp:Button>
                           </ItemTemplate>
                       </radG:GridTemplateColumn>
                        
                       <radG:GridTemplateColumn HeaderText="Complete" UniqueName="CompleteColumn" >
                           <ItemTemplate>
                               <asp:Button ID="LinkButtonCompleteCampaign" Width="60"   CommandName="CompleteCampaign" OnClientClick = "return confirm('This will only update the status of the campaign to Completed. This will not send any notification or send any emails. Do you want to complete the campaign? ');"  
                                   CommandArgument='<%# DataBinder.Eval(Container.DataItem,"[Campaign Id]") %>' runat="server"
                                   Text="Complete"></asp:Button>
                           </ItemTemplate>
                       </radG:GridTemplateColumn>
                        
                        
                   </Columns>
               </MasterTableView>
               <PagerStyle Mode="NumericPages" />
           </radG:RadGrid>
       </ContentTemplate>
       <Triggers>
            <asp:AsyncPostBackTrigger ControlID="btnSearch" EventName="Click" />
           <asp:AsyncPostBackTrigger ControlID="uxCampaignStatus" EventName="SelectedIndexChanged" />           
       </Triggers>
   </asp:UpdatePanel>

Mike
Top achievements
Rank 1
 answered on 10 May 2012
1 answer
60 views
Hi,

I have a requirement where I need to expand/shrink the cell of RadScheduler that contains more events without showing 'Show More Link', so as to fit all the events in the cell and still be made visible.

Can someone please help me with JQuery to accomplish this requirement.
Thanks a lot in advance.
Peter
Telerik team
 answered on 10 May 2012
5 answers
179 views
I am designing a site that will use telerikajax  windows to load it's controls from an xmlDocument. On the telerik window I will have several asp:Label, asp:textbox, asp:Listbox, and radgrid controls. Now, my data will consist of the content of nodes from an xmlDocument. How do I populate the telerik window's controls (bind the data) from the xml tree contained in the xmlDocument?

Thanks,

Steve Holdorf
Marin Bratanov
Telerik team
 answered on 10 May 2012
3 answers
69 views
Hi,
I have a problem, when i close a Modal using  RadWindowManager the page that contains the definition of RadWindowManager   back to the beginning of the page (lost the anchor) .

how can I solve this??

thank you,

Marin Bratanov
Telerik team
 answered on 10 May 2012
3 answers
82 views
I am updating a radgrid on my screen when I close a radwindow.  It works fine but I get extra text above and ble the grid.

 4186|updatePanel|ctl00_ContentPlaceHolder1_ctl00_ContentPlaceHolder1_Wizard1_rgImportPanel|

then the grid then

|

Any idea why?
Marin Bratanov
Telerik team
 answered on 10 May 2012
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?