Telerik Forums
UI for ASP.NET AJAX Forum
4 answers
144 views
Dear All,

I have a panelBar with different PanelItems with Templeteitems under each one reside a RadGrid.
This panel Bar is on UserControl that loaded at runtime and is already ajaxified...

I want to ajaxify the Grids, that it loads on the click of the panelitem ..

How can I accomplish this ...

Thanks and best regards,
Waleed
Waleed Seada
Top achievements
Rank 2
 answered on 27 May 2008
6 answers
234 views

Up until today this behavior never happened. Any new webform or webusercontrol I create and drop a RadPanelBar onto, the items don't expand.

I'm using RadControls for ASPNET AJAX Q1 2008 (4/14/2008)

Here's my aspx code:

<%

@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>

<%

@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>

<html xmlns="http://www.w3.org/1999/xhtml" >

<

head runat="server">

<title>Untitled Page</title>

</

head>

<

body>

<form id="form1" runat="server">

<telerik:RadScriptManager ID="RadScriptManager1" runat="server">

</telerik:RadScriptManager>

<div>

<telerik:RadPanelBar ID="RadPanelBar1" runat="server">

<CollapseAnimation Duration="100" Type="None" />

<Items>

<telerik:RadPanelItem runat="server" Text="Root RadPanelItem1">

<Items>

<telerik:RadPanelItem runat="server" Text="Child RadPanelItem 1">

</telerik:RadPanelItem>

<telerik:RadPanelItem runat="server" Text="Child RadPanelItem 2">

</telerik:RadPanelItem>

</Items>

</telerik:RadPanelItem>

</Items>

<ExpandAnimation Duration="100" Type="None" />

</telerik:RadPanelBar>

</div>

</form>

</

body>

</

html>


Any ideas why this is happening?

Thanks

Simon
Telerik team
 answered on 27 May 2008
5 answers
239 views
Hi..

I'm migrating my old modules to new version with new telerik ajax controls and I need some advices how to do it best.
At the moment I have radajaxmanager embedded in skin (skin is always one per page, so this doesnt make any problems).
Now the problem, the typicall situation in my modules:

a) users press button and in client or server side I display radconfirm
b) if user presses yes ajaxrequest is made to call server side code,
c) server side code is executed and it displays radalert with notifaction or response.redirect is made to back to main screen.

How to do it best with new ajax controls? How to use radajaxmanager and radajaxproxy?

Thanks for all info
Regards

Maria Ilieva
Telerik team
 answered on 27 May 2008
1 answer
142 views
I have come across what I think is a rather interesting issue.  When using ITemplate to create a NestedViewTemplate the InstantiateIn method gets called on the initial page load before anything has been expanded.  Is this normal behavior?  Also, when trying to view RadGrids inside that template the NeedDataSource method is not call until after the main GridDataItem has been expanded and then collapsed.  Is there any way to have NeedDataSource for the grids inside the template fire when the main GridDataItem is expanded as opposed to collapsed?
Konstantin Petkov
Telerik team
 answered on 27 May 2008
1 answer
235 views
Here's the general layout of my grid:

  • RadGrid1
    • NestedViewTemplate
      • RadMultiPage
        • RadGrid2
    • Column 2
    • Column 3
    • etc.

I need to programmatically load RadGrid2, and the parameters that I will feed into the stored procedure will come from RadGrid1. I'm not sure how to find RadGrid2, let alone how to find the columns within RadGrid2.

Thanks. Please let me know what additional information you might need.

                        
Missing User
 answered on 27 May 2008
1 answer
76 views
Hello,

I have a radgrid with a mastertableview.  Within this mastertableview I have a NestedViewTemplate that contains a tab control.  On these tab controls I have another radgrid with a mastertableview and detailtables.  It seems as if I am losing some parent/child relationship between my first mastertableview and the other mastertableview on the tab.  It seems as if you cannot set a relationship between theses to mastertable views.

Is there anyway to keep this relationship?

Missing User
 answered on 27 May 2008
1 answer
105 views
With the new release (2008.1.515.20), a javascript exception is thrown when I enter a single quote or perecent sign in a "inplace" textfield. From further investigation, I found that this exception is only thrown if AllowKeyboardNavigation is set to true.

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %> 
 
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %> 
 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> 
<html xmlns="http://www.w3.org/1999/xhtml">  
<head runat="server">  
    <title>Untitled Page</title> 
</head> 
<body> 
    <form id="form1" runat="server">  
        <asp:ScriptManager ID="ScriptManager1" runat="server" /> 
        <div> 
            <telerik:RadGrid ID="RadGrid1" runat="server"   
                OnNeedDataSource="RadGrid1_NeedDataSource">  
                <ClientSettings AllowKeyboardNavigation="true">  
                </ClientSettings>          
                <MasterTableView AutoGenerateColumns="False" DataKeyNames="Id" ClientDataKeyNames="Id" ShowHeader="true" EditMode="InPlace" CommandItemDisplay="top" > 
                    <Columns> 
                        <telerik:GridEditCommandColumn UniqueName="EditCommandColumn" ButtonType="ImageButton" />                  
                        <telerik:GridBoundColumn UniqueName="someColumn" DataField="someField" /> 
                    </Columns> 
                </MasterTableView> 
            </telerik:RadGrid></div>  
    </form> 
</body> 
</html> 
 


using System;  
using System.Data;  
using System.Configuration;  
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 _Default : System.Web.UI.Page   
{  
    protected void Page_Load(object sender, EventArgs e)  
    {  
 
    }  
    protected void RadGrid1_NeedDataSource(object source, Telerik.Web.UI.GridNeedDataSourceEventArgs e)  
    {  
        RadGrid1.DataSource = new DataTable();  
    }  
} 


So if you try out the preceeding code, press the insert new record button and try to type a single quote or percent sign in the text field.
Pavel
Telerik team
 answered on 27 May 2008
1 answer
188 views
I'm running into this problem where I can scroll to the top of the page after a call back. I have a tab strip with a multipage below it. When I scroll to the bottom to click a button, I've put this in the button click's code-behind:

        RadTabStrip tabStrip = (RadTabStrip)Page.FindControl("RadTabStrip1");
        if (checkoutTabStrip != null)
        {
            tabStrip.SelectedIndex = 1;
            tabStrip.MultiPage.SelectedIndex = 1;
        }

        RadAjaxManager.GetCurrent(this.Page).ResponseScripts.Add("window.scrollTo(0,0);");

This seems to work and when the button is clicked, the page does scroll to the top- for a second!! Then it scrolls back to the bottom where the button was clicked. I tried turning off the scroll position thru .NET but this didn't do anything:

MaintainScrollPositionOnPostback="false"

Is there a Telerik property that's controlling this? I can't seem to make my scroll to the top stick because I don't know what, but something is coming after my scrollTo(0,0) and scrolls it back down. Any ideas on this?
Yavor
Telerik team
 answered on 27 May 2008
1 answer
1.2K+ views
Hi,

I have two buttons in each gridrow. One button(openDetail) is used to open detail page as a modal popup and another button "submit" raises itemcommand event and does some data processing.

The problem that I have is once i click submit, OpenDetail button stops working(page just refreshes but doesnt open detail page).

In Item_Created Event handler I have the following code

    int Id = Convert.ToInt32(DataBinder.Eval(e.Item.DataItem, "DataId"));
               
              
               LBTN Namebtn = e.Item.FindControl("NameBTN") as BTN;
              
                Namebtn.Attributes["onclick"] = string.Format("return OpenDetail('{0}','{1}');", Id, e.Item.ItemIndex);

             

This is the OpenDetail javascript:

  function OpenDetail(id, rowIndex)
    {
       var grid = window[<%=Grid.ClientId%>];
               
        var rowControl = grid.MasterTableView.Rows[rowIndex].Control;
        grid.MasterTableView.SelectRow(rowControl, true);
                       
        window.radopen("Details.aspx?data=" + id, "Dialog");
        return false;
     }

      <telerik:RadWindowManager ID="RadWindowManager1" runat="server">
                <Windows>
                    <telerik:RadWindow ID="Dialog" runat="server" Title="Dialog" Height="400px"
                        Width="300px" Left="150px" ReloadOnShow="true" Modal="true"/>
                </Windows>
            </telerik:RadWindowManager>

Could you please tell me what I am doing wrong...

thanks..

Rosen
Telerik team
 answered on 27 May 2008
1 answer
147 views
Hello,

I have an app where I move rows between grids.  I have run into an issue because it seems like the order of grid.SelectedItems is random and not in the order of how the user clicked them  Is there a way to get grid.SelectedItems in the order of how the user clicked them?  Right now the only option is to roll my own functionality by using the row selected client event to capture the order and store it in a hidden field that I access server side to add the other grid.  I rather not do this if there is a solution or a better way accomplish this.  Any idea?

Thanks
Veli
Telerik team
 answered on 27 May 2008
Narrow your results
Selected tags
Tags
+? more
Top users last month
Shiori
Top achievements
Rank 2
Iron
Tien
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Rob
Top achievements
Rank 4
Bronze
Bronze
Iron
Geoff
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Shiori
Top achievements
Rank 2
Iron
Tien
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Rob
Top achievements
Rank 4
Bronze
Bronze
Iron
Geoff
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?