Accessing javascript function in parent page

2 posts, 0 answers
  1. iomega 55
    iomega 55 avatar
    64 posts
    Member since:
    Dec 2004

    Posted 03 Aug 2012 Link to this post

    I have a base page with the next code in the .aspx
    <telerik:RadSplitter runat="Server" ID="splMain" Width="100%" BorderSize="0"
        BorderStyle="None" PanesBorderSize="0" Height="100%" Orientation="Horizontal"
        <telerik:RadPane ID="topPane" runat="server" Height="60px" BackColor="#157164">
            <telerik:RadAjaxPanel ID="radAjaxPanel01" runat="server" LoadingPanelID="RadAjaxLoadingPanel1">
                <telerik:RadMenu id="mnuTop01" runat="server" EnableViewState="false" CausesValidation="false" OnClientItemClicked="OnClientItemClicked" CollapseAnimation-Type="None" 
            EnableShadows="true" EnableRoundedCorners="true" Style="float: none; position:absolute; top:20px; z-index:2000;" Width="100%"  >       
                <div class="div02" style="float: none; position:absolute; top:45px; height:16px; text-align:center;">
                    <asp:Label ID="lblApp" runat="server" cssclass="tb2" Text="Inicio"/>
        <telerik:RadPane runat="server" ID="pnlContenido" Scrolling="Both" ContentUrl="ePageEmpty00.aspx?a=some" ShowContentDuringLoad="false">

    vía a javascript function I change the Label (LblApp) text.

    function fnT(a) {
        var l = document.getElementById("lblApp");
        l.innerHTML = a;

    Here is myquestion, I´m loading in the pnlContenido RadPane an external .aspx, how can I change the LblApp text, from the external.aspx:
    I have tried this in the external.aspx, but it doesnt work:

    window.onload = function () {
        window.parent.fnT('Some Info');

    Can somebody help me, please.

    Thanks in advance.

  2. iomega 55
    iomega 55 avatar
    64 posts
    Member since:
    Dec 2004

    Posted 04 Aug 2012 Link to this post

    I solved with this code in the external.aspx . Very important dont place windows. at the beginning of the call to the javascript function

    <script type="text/javascript" language="javascript">
        window.onload = function () {
            parent.fnT('New text');

  3. DevCraft R3 2016 release webinar banner
Back to Top