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

I have a radsplitter on 100% height. Everything seems to be working fine until I attach a AjaxUpdatedControl to the radsplitter.

Once I attach the AjaxUpdatedControl, the height of the radsplitter seems to be fixed at a particular height. You can refer to the 2 files to see the difference.

Below are my code

Btw, this only happens in Chrome. It works fine in IE8 and Opera. Haven't tested on FF.

<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="page_defaultmainpage.aspx.cs" Inherits="TravelBooking.page_defaultmainpage" %>
<%@ 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">
 
<head id="Head1" runat="server">
    <meta http-equiv="X-UA-Compatible" content="IE=7" />
    <title>ONLINE SYSTEM</title>
    <style type="text/css">
        html, body, form
        {
            margin: 0px;
            padding: 0px;
            height: 100%;
            width: 100%;
            overflow: hidden;
        }
    </style>
</head>
<body style="height: 100%; margin: 0px; overflow: hidden;">
    <form id="form1" runat="server">
    <telerik:RadScriptManager ID="ExRadScriptManager" runat="server">
    </telerik:RadScriptManager>
    <telerik:RadAjaxManager ID="ExRadAjaxManager" runat="server">
        <AjaxSettings>
            <telerik:AjaxSetting AjaxControlID="LeftPane">
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="MainSplitter" LoadingPanelID="LoadingPanelAnimated" UpdatePanelRenderMode="Inline">
                    </telerik:AjaxUpdatedControl>
                </UpdatedControls>
            </telerik:AjaxSetting>
        </AjaxSettings>
    </telerik:RadAjaxManager>
    <telerik:RadAjaxLoadingPanel ID="LoadingPanelAnimated" runat="server" BackColor="White"
        Transparency="38" MinDisplayTime="3000" Height="800px">
        <table cellpadding="0" cellspacing="0" style="width: 100%; height: 100%;">
            <tr>
                <td align="center" valign="middle" style="padding-bottom: 100px">
                    <img alt="Loading..." src='images/ajax-loader.gif' style="border: 0;" />
                </td>
            </tr>
        </table>
    </telerik:RadAjaxLoadingPanel>
    <table style="border-style: solid; border-width: 0px 0px 2px 0px; border-color: #808080;
        width: 100%;">
        <tr>
            <td width="480">
                <asp:ImageButton ID="ImageButton1" runat="server" ImageUrl=""
                    PostBackUrl="~/management.aspx" Height="110px" />
            </td>
            <td>
                <asp:Label ID="Label1" runat="server" Font-Bold="True" Font-Names="Verdana" Font-Size="13pt"
                    Text="MAIN MANAGEMENT"></asp:Label>
            </td>
        </tr>
    </table>
    <div runat="server" id="super" style="width: 100%; height: 100%; background-color: #FF0000;">
    <telerik:RadSplitter ID="MainSplitter" runat="server" Skin="Black" Width="100%" Height="100%" HeightOffset="148" VisibleDuringInit="false">
        <telerik:RadPane ID="LeftPane" runat="server" Width="200px" BackColor="Black" BorderStyle="Solid">
            <div style="margin-top: 10px; margin-left: 8px; background-color: #000000;">
                <telerik:RadTreeView ID="ExLeftNavigator" runat="server" Skin="Black" Font-Bold="True"
                    Font-Names="Tahoma" Font-Size="8pt" >
                    <Nodes>
                        <telerik:RadTreeNode runat="server" Text="Management" Expanded="True">
                            <Nodes>
                                <telerik:RadTreeNode runat="server" Text="Option One">
                                </telerik:RadTreeNode>
                                <telerik:RadTreeNode runat="server" Text="Option Two">
                                </telerik:RadTreeNode>
                            </Nodes>
                        </telerik:RadTreeNode>
                        <telerik:RadTreeNode runat="server" Text="Booking Schedule" Expanded="True">
                            <Nodes>
                                <telerik:RadTreeNode runat="server" Text="Option Three">
                                </telerik:RadTreeNode>
                            </Nodes>
                        </telerik:RadTreeNode>
                        <telerik:RadTreeNode runat="server" Text="Others">
                        </telerik:RadTreeNode>
                    </Nodes>
                </telerik:RadTreeView>
            </div>
        </telerik:RadPane>
        <telerik:RadSplitBar ID="RadSplitBar1" runat="server" />
        <telerik:RadPane ID="ContentPane" runat="server" BackColor="White">
        </telerik:RadPane>
    </telerik:RadSplitter>
 
    <table style="border: 1px solid #808080; width: 100%; background-color: #000000;
        height: 30px;">
        <tr>
            <td width="480">
                  
                <asp:Label ID="Label3" runat="server" Text="Current Page:" Font-Bold="True" Font-Names="Tahoma"
                    Font-Size="9pt" ForeColor="White"></asp:Label>
                 <asp:Label ID="lbCurrentPage" runat="server" Font-Bold="True" Font-Names="Tahoma"
                    Font-Size="9pt" ForeColor="White"></asp:Label>
            </td>
            <td>
            </td>
        </tr>
    </table>
        </div>
    </form>
</body>
</html>
Niko
Telerik team
 answered on 29 Mar 2011
1 answer
544 views
Hi Sir,
i am binding my RadGrid with ORM like this

oadsSource.ObjectContextProvider = "RadControlApplication.EntitiesModel, RadControlApplication";
        oadsSource.TypeName = "RadControlApplication.TblCustomer";
        oadsSource.EnableDelete = false;
        oadsSource.EnableUpdate = false;
        oadsSource.EnableInsert = false;
        oadsSource.StoreOriginalValuesInViewState = false;
        rdGridCustomer.DataSourceID = "oadsSource";


here oadsSource is the object of my OpenAccessDataSource control, that i put in my aspx page.
and RadGrid is bound properly.


i am setting the properties of my radGrid for Excel Exporting as
        rdGridCustomer.ExportSettings.FileName = "MyDataFile";
        rdGridCustomer.ExportSettings.ExportOnlyData = true;
        rdGridCustomer.ExportSettings.IgnorePaging = false;
        rdGridCustomer.ExportSettings.OpenInNewWindow = true;
        rdGridCustomer.ExportSettings.Excel.FileExtension = "xls";
        rdGridCustomer.ExportSettings.Excel.Format = Telerik.Web.UI.GridExcelExportFormat.ExcelML;

  now on button click event i am writing this code

  this.rdGridCustomer.MasterTableView.ExportToExcel();
but i am facing the error
Key cannot be null. Parameter name: key
But if i bind my RadGrid with other data source like SQLDATASOURCE then its work fine.no error occurs.
and if i use other datasource like datatable then also its work fine for export in ExcelML format.
But i have to use ORM actuly.
I need solution please.
Thanks very much
Damyan Bogoev
Telerik team
 answered on 29 Mar 2011
1 answer
158 views
Good morning,

We have a page from which users can upload big files. We are using asyncUpload control to achieve this. 

In development enviroment, progress bar moves in a fluent way but, when in production, progress bar only makes 3 steps (not always the same, but very strange, because first step always starts over the 30%).

May we configure something to make this progress indicator more fluid?

Thank you very much
Genady Sergeev
Telerik team
 answered on 29 Mar 2011
1 answer
130 views
I was using the Telerik suite for a project and then upgraded to the most recent version when items in our RadWindows would go blank and FireBug would report a "Telerik is not defined" error. I swept the forums for a solution and everything pointed to the fact that we had to review our web.config or our caching.

Neither was an issue.

However, we solved the problem by removing the CdnSettings variable "TelerikCdn = 'Enabled'" and changed it to "Disabled". It appears that Telerik may not have updated their code in the cloud.

The following is our .NET block and the bold line is what was incorrect.

<telerik:RadScriptManager ID="RadScriptManager1" runat="server"
        EnablePartialRendering="true" EnableScriptCombine="True"
        EnableViewState="false"   ScriptMode="Release"
        LoadScriptsBeforeUI="false" CompositeScript-ScriptMode="Release">
        <CdnSettings TelerikCdn="Enabled" BaseUrl="~/js" />
</telerik:RadScriptManager>



Hope it helps.
Simon
Telerik team
 answered on 29 Mar 2011
1 answer
112 views
Hi Telerik Team,

i just upgraded my telerik version from Q3 2009 to Q3 2010.
now when i am opening a normal window (not rad window) from javascript, it open the window and automatically minimising .
it need to reopen agin from windows task bar.
if it is Rad Window , there is no problem.
it is happening when replaced the telerik dll to Q3 2010. if i replace the dll to Q3 2009, it is working ok.
please let me know what the updation i need to do in Q3 2010 version.

below the code i used.
function Popup_normal(url, title, width, height) {
  
            var l = (screen.width - width) / 2;
            var t = (screen.height - height) / 2;
            var feature = "width=" + width + ",height=" + height + ",left=" + l + ",top=" + t + ",scrollbars=1,resizable=1";
     
            mywindow = window.open(url, "title", feature);
            return false;
        }
Marin Bratanov
Telerik team
 answered on 29 Mar 2011
2 answers
173 views
This is very strange, it seems like our main RadTabStrip (used for navigation) does not seem to remember it's ViewState, even though it is set to true, and all other controls in the samce User Control has working viewstates. You can see this as changing the SelectedIndex doesn't seem to have any effect (all settings seem to reset to those in the .ascx file), and that events like Init() is called on every postback.

Any ideas what to look for here? Don't really know where to start since ViewState is enabled and working for eveything else? Tried experimenting with AutoPostback etc but that doesnt seem to have any effect.
improwise
Top achievements
Rank 1
Iron
Iron
 answered on 29 Mar 2011
1 answer
253 views
I am using the RadUpload control along with the Rad Progress bar. This was working fine for more than year. Recently we had to add another HttpModule to track the Url in our website. Since then the Rad Progress bar does not show at all. I even downloaded the latest Telerik demo project and added  a simple TestModule. This also breaks the Rad Progress bar.   

using System;
using System.Collections.Generic;
using System.Text;
using System.Web;
using System.Configuration;
 
namespace HttpModules
{
    public class TestModule : IHttpModule
    {
        protected log4net.ILog logger = log4net.LogManager.GetLogger("File");
 
        public void Init(HttpApplication app)
        {
            app.BeginRequest += new EventHandler(OnBeginRequest);
        }
 
        public void OnBeginRequest(Object sender, EventArgs e)
        {
            try
            {
                logger.InfoFormat("TestModule => OnBeginRequest");
 
                HttpApplication app = (HttpApplication)sender;
                HttpContext context = app.Context;
 
                logger.InfoFormat("TestModule => This is just a Test module");
 
                if (IsTelerikRequest(context.Request))
                    return;
 
                string source = context.Request["source"];
 
                if (!string.IsNullOrEmpty(source))
                {
                    logger.InfoFormat("TestModule => source is {0} ", source);
                }
 
            }
            catch(Exception ex)
            {
                logger.Error("Error in Test Module", ex);
            }
        }
 
        private bool IsTelerikRequest(HttpRequest httpRequest)
        {
            logger.InfoFormat("TestModule => IsTelerikRequest (httpRequest.RawUrl : '{0}')", httpRequest.RawUrl);
            return httpRequest.RawUrl.Contains("RadUploadProgressHandler.ashx");
        }
 
        private static bool IsAjaxRequest(HttpRequest request)
        { 
            if (request == null) 
            {
                throw new ArgumentNullException("request");
            } 
            
            return (request["X-Requested-With"] == "XMLHttpRequest") || ((request.Headers != null) && (request.Headers["X-Requested-With"] == "XMLHttpRequest")); 
        }
 
        public void Dispose() 
        {
 
        }
    }
}
Dimitar Terziev
Telerik team
 answered on 29 Mar 2011
3 answers
180 views
Hello,

I am using the trial version of Telerik ASP.NET controls. I came across the following 2 issues:

1. Adding custom command to the raddoc then its images are not appearing on the DocTitleBar.

.rdCustomize
  {
      width: 25px;
      height: 25px;
      cursor: pointer;
      background: url('../Images/1.gif') transparent !important;
  }

<telerik:RadDock ID="RadDock1" runat="server" Width="250px" EnableAnimation="true"
                                            Height="250px" Resizable="true" Skin="Sitefinity" Tag="CSMD_Average_Response_Time"
                                            Title="1">
                                            <Commands>
                                                <telerik:DockCloseCommand />
                                                <telerik:DockExpandCollapseCommand />
                                                <telerik:DockCommand CssClass="rdCustomize" Name="doEdit" Text="Customize" />
                                                <telerik:DockCommand CssClass="rdCustomize" Name="doRefresh" Text="Refresh" />
                                            </Commands>
                                            <ContentTemplate>
                                                <div>
                                                    <uc:AvgResolutionTimeFL ID="CSMD_AvgResolutionTimeFL" runat="server"></uc:AvgResolutionTimeFL>
                                                </div>
                                            </ContentTemplate>
                                        </telerik:RadDock>

2. Surprisingly I got error messages on the design window. Plz find the attachment for it.

Can you plz suggested me to do this the better manner ?
Pero
Telerik team
 answered on 29 Mar 2011
2 answers
142 views
I am trying to make a page which operates mostly on the client with radrotator.  you can think of it as a simple slide-show type interface.  radrotator has thumbnails, which switching between index, larger image updates (along with some other things)

I am using hash parameters in the URL to allow users to "bookmark" pages meaningfully, and below is what i see as the relevant javascript code.

i use a boolean "stateHandled" variable which lets the code know whether or not it should look at the hash value and update the page accordingly, or if the state change has already been handled....

thus, if user presses back button, the onhashchange event updates the gui.
on the other hand, if user interacts with the radrotator - the onhashchange event does nothing.

what is REALLY weird is that all of this works fine except for one thing...  the animation of the radrotator is suppressed now for when the user is changing the index via interactions with the radrotator, but the forward/back buttons of the browser work fine (they have animation).

window.onload = function () {
    initializeStateFromURL();
}
  
window.onhashchange = function () {
    initializeStateFromURL();
}
  
function initializeStateFromURL() {
    if (!stateHandled) {
        var navSetting = window.location.hash;
        var slide = FromHash("slide", navSetting);
        if (slide) {
            SetRotatorToSlideID(slide);
        }
    }
}
  
var stateHandled = false;
  
function SetRotatorToSlideID(slideID) {
    var items = rotator.get_items();
    for (i in items) {
        if (slideID == GetAttributeValue(items[i], "SlideID")) {
            rotator.set_currentItemIndex(items[i].get_index(), true);
            UpdateGUI(items[i]);
        }
    }
}
  
function RotatorClientItemShowing(sender, args) {
    stateHandled = true;
    UpdateGUI(args.get_item());
    stateHandled = false;
}
  
function RotatorClientItemClicked(sender, args) {
    stateHandled = true;
    sender.set_currentItemIndex(args.get_item().get_index(), true);
      
    UpdateGUI(args.get_item());
    stateHandled = false;
}
  
function UpdateGUI(item) {
    //update some things on the page
  
    setHash(GetAttributeValue(item,"DocumentID"),GetAttributeValue(item,"SlideID"));
}


on the other hand, if i make the changes to the above code, having:

function RotatorClientItemShowing(sender, args) {
    stateHandled = true;
    UpdateGUI(args.get_item());
}
   
function RotatorClientItemClicked(sender, args) {
    stateHandled = true;
    sender.set_currentItemIndex(args.get_item().get_index(), true);
       
    UpdateGUI(args.get_item());
}


then the animations work fine...  (however the logic of the code isn't exactly perfect... the forward/back buttons only work every other hash change)

any ideas?  thanks.
Felipe
Top achievements
Rank 1
 answered on 29 Mar 2011
1 answer
103 views
Hi there,

Are you planing to support Telerik RadInput with the RadInputManager?  This is great for standard ASP.Net controls, but what if our page already is using telerik controls?  It would be great to be able to benefit the optimization of the InputManager with Telerik controls as well.

Thanks.
Maria Ilieva
Telerik team
 answered on 29 Mar 2011
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?