Index.aspx contains a RadtabStrip and RadMultiPage. From Index.aspx, I am trying to call a JavaScript function found in selected PageView's content, which is another ASPX page. My JavaScript in Index.aspx that is trying to make the call to Page VIew looks like this (saveData is the function in the child ASPX page):
var multiMain = $find("<%= mulMain.ClientID %>");
var pageToSave = multiMain.get_selectedPageView();
var pageContent = pageToSave.get_element();
pageContent.saveData()
;
Obviously, I can't get this to work. I can see from the examples that you can change style information, among a number of other things, but it appears that I'm doing so for the immediate container of the child ASPX (an iframe), and not for the ASPX page itself.
Does anyone have any idea how to pull this off, how to call the JavaScript of an ASPX page contained within a Page View of RadMultiPage?
Good day,
I want to know if there is any way to post back to radWindow on maximize/minimize.
I am using RadChat in the radWindow and I need to resize it on maximize/minimize.
Thanks,
Regards
telerik:RadRotator ID="RadRotatorHorizontal" <%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="News.Default" %><%@ Register TagPrefix="telerik" Namespace="Telerik.Web.UI" Assembly="Telerik.Web.UI" %><!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>Rotator Page</title> <style type="text/css"> .itemTemplate { width: 250px; height: 40px; } .rotatatorLeftRightBack, .rotatatorUpDownBack { float: left; background-repeat: no-repeat; padding-left: 30px; padding-top: 20px; width: 407px; height: 43px; } .floatRotator { float: left; margin-top: -5px; } .start, .stop, .left, .right, .up, .down, .startSelected, .stopSelected { width: 20px; height: 20px; display: block; cursor: hand; outline: none; } #navigationHorizontal .start, #navigationHorizontal .stop, .left, .right, #navigationHorizontal .startSelected, #navigationHorizontal .stopSelected { background-image: url('IMAGES/HorizontalButtons.gif'); } #navigationVertical .start, #navigationVertical .stop, .up, .down, #navigationVertical .stopSelected, #navigationVertical .startSelected { background-image: url('IMAGES/VerticalButtons.gif'); } .start span, .stop span, .left span, .right span, .down span, .up span, .stopSelected span, .startSelected span { width: 20px; height: 20px; display: block; text-indent: -500000px; } .stopSelected { background-position: 0px -25px; } .startSelected { background-position: -25px -25px; } .stop { background-position: 0px 0px; } .start { background-position: -25px 0px; } .left { background-position: -50px 0px; } .right { background-position: -75px 0px; } .down { background-position: -50px 0px; } .up { background-position: -75px 0px; } /* Hovers */.stop:hover { background-position: 0px -25px; } .start:hover { background-position: -25px -25px; } .stop:hover { background-position: 0px -25px; } .left:hover { background-position: -50px -25px; } .right:hover { background-position: -75px -25px; } .down:hover { background-position: -50px -25px; } .up:hover { background-position: -75px -25px; } .commandsWrapper, .commandsWrapper li { float: left; margin: 0; padding: 0; border: 0; list-style: none; height: auto; display: block; } .commandsWrapper { width: 136px; height: 20px; padding: 2px 0 0 10px; } .commandsWrapper li { margin-right: 14px; _margin-right: 13px; /* START IE6 hack */ } .commandsWrapper ul:after { content: ""; display: block; height: 0; overflow: hidden; line-height: 0; font-size: 0; clear: both; visibility: hidden; } .title { font-size: 20px; margin-bottom: 15px; } </style> </head><body class="BODY"> <form id="Form1" method="post" runat="server"> <telerik:RadScriptManager ID="ScriptManager1" runat="server"> </telerik:RadScriptManager> <script type="text/javascript"> //<![CDATA[ function GetRotator() { //return $find('<%#RadRotatorHorizontal.ClientID %>'); return document.getElementById(RadRotatorHorizontal); } //]]> </script> <script type="text/javascript"> //<![CDATA[ function startRotator(clickedButton, rotator, direction) { if (!rotator.autoIntervalID) { refreshButtonsState(clickedButton, rotator); rotator.autoIntervalID = window.setInterval(function () { rotator.showNext(direction); }, rotator.get_frameDuration()); } } function stopRotator(clickedButton, rotator) { if (rotator.autoIntervalID) { refreshButtonsState(clickedButton, rotator) window.clearInterval(rotator.autoIntervalID); rotator.autoIntervalID = null; } } function showNextItem(clickedButton, rotator, direction) { rotator.showNext(direction); refreshButtonsState(clickedButton, rotator); } // Refreshes the Stop and Start buttons function refreshButtonsState(clickedButton, rotator) { var jQueryObject = $telerik.$; var className = jQueryObject(clickedButton).attr("class"); switch (className) { case "start": {// Start button is clicked jQueryObject(clickedButton).removeClass(); jQueryObject(clickedButton).addClass("startSelected"); // Find the stop button. stopButton is a jQuery object var stopButton = findSiblingButtonByClassName(clickedButton, "stopSelected"); if (stopButton) {// Changes the image of the stop button stopButton.removeClass(); stopButton.addClass("stop"); } } break; case "stop": {// Stop button is clicked jQueryObject(clickedButton).removeClass(); jQueryObject(clickedButton).addClass("stopSelected"); // Find the start button. startButton is a jQuery object var startButton = findSiblingButtonByClassName(clickedButton, "startSelected"); if (startButton) {// Changes the image of the start button startButton.removeClass(); startButton.addClass("start"); } } break; } } // Finds a button by its className. Returns a jQuery object function findSiblingButtonByClassName(buttonInstance, className) { var jQuery = $telerik.$; var ulElement = jQuery(buttonInstance).parent().parent(); // get the UL element var allLiElements = jQuery("li", ulElement); // jQuery selector to find all LI elements for (var i = 0; i < allLiElements.length; i++) { var currentLi = allLiElements[i]; var currentAnchor = jQuery("A:first", currentLi); // Find the Anchor tag if (currentAnchor.hasClass(className)) { return currentAnchor; } } } //]]> </script> <table> <tr> <td class="style1"> <div class="rotatatorLeftRightBack"> <telerik:RadRotator ID="RadRotatorHorizontal" runat="server" ScrollDuration="50" RegisterWithScriptManager="true" Height="250px" Width="490px" RotatorType="FromCode" ScrollDirection="Left" CssClass="floatRotator"> <ItemTemplate> <div class="itemTemplate"> <%# XPath("Title") %> </div> </ItemTemplate> </telerik:RadRotator> <button onclick="$find('<%#RadRotatorHorizontal.ClientID%>').showNext(Telerik.Web.UI.RotatorScrollDirection.Left);" type="button" class="left"> </button> <button onclick="$find('<%#RadRotatorHorizontal.ClientID%>').showNext(Telerik.Web.UI.RotatorScrollDirection.Right);" type="button" class="right"> </button> <a onclick='javascript:alert(getRotator());'>Testing</a> <a onclick='javascript:alert($find("RadRotatorHorizontal_ClientState"));'>jstest</a>; <ul id="navigationHorizontal" class="commandsWrapper"> <li><a href="#" onclick="stopRotator(this, $find('<%#RadRotatorHorizontal.ClientID%>')); return false;" class="stopSelected" title="Stop"><span>Stop</span></a></li> <li><a href="#" onclick="startRotator(this, $find('<%#RadRotatorHorizontal.ClientID%>'), Telerik.Web.UI.RotatorScrollDirection.Left); return false;" class="start" title="Start"><span>Start</span></a></li> <li><a href="#" onclick="showNextItem(this, $find('<%#RadRotatorHorizontal.ClientID%>'), Telerik.Web.UI.RotatorScrollDirection.Left); return false;" class="left" title="Left"><span>Up</span></a></li> <li><a href="#" onclick="showNextItem(this, $find('<%#RadRotatorHorizontal.ClientID%>'), Telerik.Web.UI.RotatorScrollDirection.Right); return false;" class="right" title="Right"><span>Down</span></a></li> </ul> </div> </td> </tr> </table> </form> </body></html>