Telerik Forums
UI for ASP.NET AJAX Forum
4 answers
159 views
Hi,

I noticed that when I set the EnablePostBackOnRowClick property to true in the ClientSettings of the RadGrid, the client event OnCommand is not fired when the command is "RowClick". The server-side event is fired w/o any issues.

When the EnablePostBackOnRowClick property is set to false, OnCommand is fired fine on the client side when i click a row.

Is this a bug or is it intended behavior?

Thank you.
blablabla
Top achievements
Rank 1
 answered on 19 Jan 2012
1 answer
217 views
Is it possible to instruct the RadAjaxManager to only update a Repeater control on its ItemCommand event. This does not seem to isolate the update to the repeater...

<telerik:AjaxSetting AjaxControlID="rptPromotionPages">
    <UpdatedControls>
        <telerik:AjaxUpdatedControl ControlID="rptPromotionPages" />
    </UpdatedControls>
</telerik:AjaxSetting>

Does anyone know how to accomplish this?

Duncan
Jayesh Goyani
Top achievements
Rank 2
 answered on 19 Jan 2012
1 answer
58 views
Hi,

My scheduler control is inside a user control, I am populating it from code behind using a custom class, now when calendar finishes populating data , I want to fire a javascript metod. Please let me know how to achieve this.
Ivana
Telerik team
 answered on 19 Jan 2012
1 answer
83 views
Hi Guys,

I was hoping you may be able to assist me in overriding your default styles. I have my own skin applied to a panel and everything works and looks as it should. There are a few discrepancies between browsers and to get around these I need to be able to amend the padding on .rpimage.

I have a class as follows to try and alter the padding:

.RadPanelBar_MySkin .rpImage
{
    padding-bottom: 10px !important;
}

However this is still being overridden by .RadPanelBar .rpImage. Is there a way that I can overide this and set the image padding myself?

Thanks as always for your help.
Kate
Telerik team
 answered on 19 Jan 2012
1 answer
68 views
Hi,
  I need small guidance in customizing select location during file upload. Is it possible to target a client location while pressing Select for uploading a file?
Case: There is a folder named vinoth in my client system. Whenever i login with my credential i have  to open that folder by default during upload file select in client so that i can easily pic files from my folder directly. Can you please let me know if this facility is available in Radupload control.

Thanks and Regards,
 VINOTH
Kate
Telerik team
 answered on 19 Jan 2012
4 answers
196 views


Posted 11 minutes ago (permalink)

I have the following aspx code in a usercontrol:

<telerik:RadTabStrip ID="radTSCapabilities" runat="server" SelectedIndex="0" Skin="Default" MultiPageID="radMPCapabilities" />
    <telerik:RadMultiPage ID="radMPCapabilities" runat="server" SelectedIndex="0" />

I dynamically create the Tabs and PageViews from the code behind on load.  Inside the PageView is a RadTreeView.  See code below:
Telerik.Web.UI.RadPageView tmpPageView = new Telerik.Web.UI.RadPageView();
tmpPageView.ID = type.AbilityType.Name;
radMPCapabilities.PageViews.Add(tmpPageView);
 
//Add a Tab for the AbilityType
Telerik.Web.UI.RadTab tmpTab = new Telerik.Web.UI.RadTab(type.AbilityType.Name, type.AbilityType.ID.ToString());
tmpTab.PageViewID = tmpPageView.ID;
radTSCapabilities.Tabs.Add(tmpTab);
 
//Create and Load the Rad Tree
Telerik.Web.UI.RadTreeView radTree = new Telerik.Web.UI.RadTreeView();
radTree.Skin = "Default";
radTree.CheckBoxes = true;
radTree.TriStateCheckBoxes = true;
radTree.CheckChildNodes = true;
radTree.NodeDataBound += new Telerik.Web.UI.RadTreeViewEventHandler(radTree_NodeDataBound);
radTree.ID = type.AbilityType.ID.ToString() + type.AbilityType.Name.Replace(" ""_");
radTree.DataTextField = "Name";
radTree.DataValueField = "ID";
radTree.DataFieldID = "ID";
radTree.DataFieldParentID = "ParentID";
 
//If there are multiple Ability Types in result set then go to the DB to get all Abilities for that type
if (distinctAbilityTypes.Count() != 1)
    radTree.DataSource = AbilityMgr.GetAbilitiesByAbilityTypeID(type.AbilityType.ID);
else
    radTree.DataSource = tmpAbilities;
 
//Bind the Tree
radTree.DataBind();
 
//Add a top border
Literal tmpLiteral = new Literal();
tmpLiteral.Text = "<div style='border-top:solid 1px #AAAAAA;'></div>";
 
//Add the Literal and Tree to the associated PageView
radMPCapabilities.FindControl(type.AbilityType.Name).Controls.Add(tmpLiteral);
radMPCapabilities.FindControl(type.AbilityType.Name).Controls.Add(radTree);

I am trying to get a reference to the dynamically created RadTreeView.  I have been unable to do so for some time now.  Please help.
Chris Salas
Top achievements
Rank 1
 answered on 19 Jan 2012
1 answer
196 views
Hey,

I have a RadSplitter with RadPanes, RadSplitBars, ...
Is it possible to set scroll position of a RadSlidingPane when I'm scrolling an another RadPane?

For exemple, when I click a node in the first RadPane : the same node is clicked in the RadSlidingPane.
When I expand a node in the first RadPane...

But I'd like to have the same rendering when I scroll the first pane and I can't move the content of the RadSlidingPane.

I hope you understand me

Thanks

    Michel
Michel
Top achievements
Rank 1
 answered on 19 Jan 2012
1 answer
164 views
I have a scenario where clicking on a control asynchronously loads other control. I have refereed the thread mentioned in "http://www.telerik.com/community/forums/aspnet-ajax/ajax/radajax-manager-does-not-load-js-files-in-dynamically-loaded-user-control.aspx". Used the application website5 provided in the link. If i add an update panel in the provided sample then the JavaScript is not getting loaded.

Code: Default.aspx
 <%@ 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.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>Untitled Page</title>
</head>
<body>
    <form id="form1" runat="server" enableviewstate="false">
    <div>
        <telerik:RadScriptManager runat="server" ID="ScriptManager1">
        </telerik:RadScriptManager>
        <telerik:RadSplitter ID="RadSplitter1" runat="server" Height="100%" Width="100%">
            <telerik:RadPane ID="LeftPane" runat="server" Width="300px" Scrolling="None" MinWidth="200"
                Height="100%">
                <asp:Button runat="server" ID="Button1" Text="Load Control 1" OnClick="Button1_Click" />
            </telerik:RadPane>
            <telerik:RadSplitBar ID="RadSplitBar2" runat="server" CollapseMode="Forward" />
            <telerik:RadPane ID="MainPane" runat="server" Scrolling="None">
                <telerik:RadSplitter runat="server" Orientation="Horizontal">
                    <telerik:RadPane ID="RadPane2" runat="server" Height="15%" MaxHeight="300">
                        <div class="qsfexHeader">
                            Search Pane
                        </div>
                    </telerik:RadPane>
                    <telerik:RadSplitBar ID="RadSplitBar1" runat="server" CollapseMode="Forward" />
                    <telerik:RadPane ID="RadPane1" runat="server" Scrolling="None">
                        <telerik:RadSplitter ID="RadSplitter3" runat="server" Orientation="Vertical" CssClass="SplitterResultsReading"
                            Width="100%">
                            <telerik:RadPane ID="RadPane3" runat="server" MinWidth="300" Scrolling="None">
                                <asp:UpdatePanel ID="UpdatePanel1" UpdateMode="Conditional" runat="server">
                                    <ContentTemplate>
                                        <telerik:RadSplitter ID="RadSplitter4" runat="server" Orientation="Horizontal">
                                            <telerik:RadPane runat="server" ID="ResultViewPane" Scrolling="None">
                                                <asp:PlaceHolder runat="server" ID="PlaceHolder1"></asp:PlaceHolder>
                                            </telerik:RadPane>
                                        </telerik:RadSplitter>
                                    </ContentTemplate>
                                    <Triggers>
                                        <asp:AsyncPostBackTrigger ControlID="Button1" />
                                    </Triggers>
                                </asp:UpdatePanel>
                            </telerik:RadPane>
                            <telerik:RadSplitBar ID="RadSplitBar4" runat="server" CollapseMode="Backward" />
                            <telerik:RadPane ID="RadPane4" runat="server" Scrolling="Both" MinWidth="300">
                                <asp:Button runat="server" ID="Button2" Text="Load Control 2" OnClick="Button2_Click" />
                            </telerik:RadPane>
                        </telerik:RadSplitter>
                    </telerik:RadPane>
                </telerik:RadSplitter>
            </telerik:RadPane>
        </telerik:RadSplitter>
    </div>
    </form>
</body>
</html>
Default.aspx.cs

using System;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;

public partial class _Default : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        if (IsPostBack && ViewState["LastLoadedControl"] != null)
        {
            string controlName = (string) ViewState["LastLoadedControl"];
            Control control = PlaceHolder1.FindControl(controlName);
            if (control != null)
            {
                PlaceHolder1.Controls.Remove(control);
            }

            control = LoadControl(string.Format("~/{0}.ascx", controlName));
            control.ID = controlName;
            PlaceHolder1.Controls.Add(control);
        }
    }

   

    protected void Button1_Click(object sender, EventArgs e)
    {
        Load();
     //   ViewState["LastLoadedControl"] = "WebUserControl";
    }

    private void Load()
    {
        Control control = LoadControl("~/WebUserControl.ascx");
        control.ID = "WebUserControl";
        PlaceHolder1.Controls.Clear();
        PlaceHolder1.Controls.Add(control);
    }

    protected void Button2_Click(object sender, EventArgs e)
    {
        Control control = LoadControl("~/WebUserControl.ascx");
        control.ID = "WebUserControl";
        PlaceHolder1.Controls.Clear();
        PlaceHolder1.Controls.Add(control);
    }

}

Webusercontrol.ascx

<%@ Control Language="C#" AutoEventWireup="true" CodeFile="WebUserControl.ascx.cs" Inherits="WebUserControl" %>
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>

<telerik:RadScriptBlock runat="server" ID="RadScriptBlock1">
    <script type="text/javascript">
        function pageLoad() {
            alert('Hello from user control <%=ID %>');
        }

        function sayHello()
        {
            alert('Hello again!');
            alert("<%=Button1.ClientID %>");
        }

        function Sample(sender, args) {

            alert("grid created");
        }
               
    </script>    

</telerik:RadScriptBlock>

<asp:Label runat="server" ID="Label1"/>
<asp:Button runat="server" ID="Button1" OnClientClick="sayHello()" Text="Click ME"/>
<telerik:RadGrid ID="RadGrid1" runat="server"  AutoGenerateColumns="true">
 <ClientSettings EnableAlternatingItems="false" EnableRowHoverStyle="True">
                <ClientEvents OnGridCreated="Sample" />
                </ClientSettings>
</telerik:RadGrid>
<div id="panel">
</div>

On clicking of button 1 i am getting JavaScript error "Sample is undefined" .

Jayesh Goyani
Top achievements
Rank 2
 answered on 19 Jan 2012
2 answers
525 views
Hi,
 I have a radgrid with some image column and other data columns with following configuration.
  static headers, column resizing and clip cell content on resize.

I have set image columns width in code behind in pixels and resizable=false. But when I resize other data columns image column also resizes. I don't want them to get resized. 
 
regards,
Mahesh
Rashmi
Top achievements
Rank 1
 answered on 19 Jan 2012
6 answers
171 views
I have a simple search page that contains a a RadComboBox and some text boxes.  When the user submits the form it displays results on a new page for the user.  When the user hits the browser's back button in IE, the user values in the text boxes and combo box are selected.  When I try the same thing in Firefox or Chrome, only the contents of the text boxes are displayed and the combo box reverts to its original value.

I have tried with versions 2008.1.619.20, 2009.1.527.20 and 2010.3.1317.20, but get the same results.

Any thoughts?  Is this the expected result for Firefox and Chrome?

Thanks!

Hans Gunnar
Top achievements
Rank 1
 answered on 19 Jan 2012
Narrow your results
Selected tags
Tags
+? more
Top users last month
Boardy
Top achievements
Rank 2
Veteran
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
ivory
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ClausDC
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Boardy
Top achievements
Rank 2
Veteran
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
ivory
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ClausDC
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?