get_width inconsistency

2 posts, 0 answers
  1. Antony
    Antony avatar
    41 posts
    Member since:
    Jan 2009

    Posted 03 Feb 2009 Link to this post


    I'm using RadPanel.get_width() to set the width of elements contained within the panel. However, the get_width() function doesn't consistently return the same thing. Sometimes it will return a number and other times it will return a string. 

    For example, if the width is 170 pixels then sometimes it will return '170' and other times it will return '170px'. Is this a bug or am I missing something?



  2. Tsvetie
    Tsvetie avatar
    1517 posts

    Posted 06 Feb 2009 Link to this post

    Hello Antony,
    I tried to reproduce the inconsistency you describe, but to no avail. I used the following code for my test:
    <telerik:RadSplitter ID="RadSplitter1" runat="server"
        <telerik:RadPane ID="RadPane1" runat="server" Width="170px"
            <button onclick="GetWidth(); return false;">get_width</button> 
        <telerik:RadSplitBar ID="RadSPlitBar1" runat="server" /> 
        <telerik:RadPane ID="RadPane2" runat="server"></telerik:RadPane> 
    <script type="text/javascript"
    function GetWidth() 
        var pane = $find('<%= RadPane1.ClientID %>'); 

    Could you please prepare and send us a simple running project, demonstrating the problem? Once we are able to reproduce it locally, we will do our best to find what causes it.

    Sincerely yours,
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Back to Top