Having problem with image displaying correctly

2 posts, 0 answers
  1. Brett
    Brett avatar
    72 posts
    Member since:
    Mar 2012

    Posted 22 Feb 2011 Link to this post

    I am having a problem with an image displaying correctly in my RadRotator.  It appears that the image is zoomed in and far too large.  Below is my code for the RadRotator, now what could possibly be the problem?:

     

     

     

    <telerik:RadRotator ID="RadRotator1" runat="server" FrameDuration="4000"

     

     

     

    Width="100%" ItemWidth="100%" Height="400px" ItemHeight="400px" ScrollDirection="Left">

     

     

     

    <Items>

     

     

     

    <telerik:RadRotatorItem ID="item1" runat="server" >

     

     

     

    <ItemTemplate>

     

     

     

    <asp:Image ID="Image1" runat="server" Width="100%" ImageUrl="~/images/managedservices.jpg" />

     

     

     

    </ItemTemplate>

     

     

     

    </telerik:RadRotatorItem>

     

     

     

    <telerik:RadRotatorItem ID="item2" runat="server" >

     

     

     

    <ItemTemplate>

     

     

     

    <asp:Image ID="Image2" runat="server" Width="100%" ImageUrl="~/images/ANTON.jpg" />

     

     

     

    </ItemTemplate>

     

     

     

    </telerik:RadRotatorItem>

     

     

     

    <telerik:RadRotatorItem ID="item3" runat="server" >

     

     

     

    <ItemTemplate>

     

     

     

    <asp:Image ID="Image3" runat="server" Width="100%" ImageUrl="~/images/BOTTM.jpg" />

     

     

     

    </ItemTemplate>

     

     

     

    </telerik:RadRotatorItem>

     

     

     

    </Items>

     

     

     

    </telerik:RadRotator>

     

  2. Marin Bratanov
    Admin
    Marin Bratanov avatar
    3598 posts

    Posted 23 Feb 2011 Link to this post

    Hi Brett,

    Setting the image width and item width to 100% makes the image fill up the whole viewport (that is zoom in). Especially if the aspect ratio of the image and the RadRotator are not the same you will experience incorrect display.

    The Width and ItemWidth properties should be set in pixels and should correspond to the actual size of the images. The images, on the other hand, should be edited to such a size and aspect ratio so that they fit correctly in the viewport so that declaring a width property for them is not necessary. Please, see the How to configure RadRotator help article for a more visual explanation.


    Best wishes,
    Marin
    the Telerik team
    Registration for Q1 2011 What’s New Webinar Week is now open. Mark your calendar for the week starting March 21st and book your seat for a walk through all the exciting stuff we ship with the new release!
  3. UI for ASP.NET Ajax is Ready for VS 2017
Back to Top