This is a migrated thread and some comments may be shown as answers.

Radrotator inside modalpopup

3 Answers 68 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Sanjay Sangal
Top achievements
Rank 1
Sanjay Sangal asked on 18 Apr 2011, 07:36 AM
Hi,
I am using Radrotator  control inside modalpopup(using modalpopup extender). But while i am running my project and show modalpopup Radrotator  is not displaying. Normally it is working fine(without modalpopup).
Can you please tell me why it is happening?.

3 Answers, 1 is accepted

Sort by
0
Marin Bratanov
Telerik team
answered on 19 Apr 2011, 08:13 AM

Hi Sanjay,

I have answered your other thread on the matter, but for your convenience and to help other that may encounter a similar issue I am pasting the reply here as well:

By default, RadRotator has visibility hidden and after page is initialized it is changed to visible. In your case this visibility change is prevented, so you should do it yourself.

 For example you could repaint the Rotator after you show it:

$find("<%= RadRotator1.ClientID %>").repaint();

If this does not work you could try to set a timeout:

setTimeout(function() {$find("<%= RadRotator1.ClientID %>").repaint();}, 500);

Another approach is to check whether its wrapper is somehow hidden (either by the visibility or by the display property). You can get a reference to the wrapper by using the getElementById() method or by inspecting the DOM by using the Developer Toolbar or a tool like FireBug:

var rotatorWrapper = document.getElementById("RadRotator1");

If the above does not help you solve the issue please send us a runnable sample displaying the issue so we can pinpoint the cause.




Kind regards,
Marin
the Telerik team

Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.

0
Ritesh
Top achievements
Rank 1
answered on 08 Oct 2012, 12:49 PM
Hi ,

I am binding Telerik rad roatater dynamically on modal popup  but it is not displaying on ,please help me on this.


Thanks
0
Shinu
Top achievements
Rank 2
answered on 09 Oct 2012, 05:13 AM
Hi,

Here is the full code that I tried to show a rotator inside  a ModalPopupExtender.
aspx:
<ajaxToolkit:ModalPopupExtender ID="ModalPopupExtender1" runat="server"  TargetControlID="Button1" PopupControlID="RadRotator1"></ajaxToolkit:ModalPopupExtender>
 <telerik:RadRotator ID="RadRotator1" runat="server" Width="100" ItemWidth="100" Height="110"
    ItemHeight="110">
    <ItemTemplate>
      <div>
       <%# Container.DataItem %>
      </div>
  </ItemTemplate>
</telerik:RadRotator>
<asp:Button ID="Button1" runat="server" Text="Button" />
C#:
protected void Page_Load(object sender, EventArgs e)
   {
       List<string> list = new List<string>() { "Item 1", "Item 2", "Item 3" };
       RadRotator1.DataSource = list;
       RadRotator1.DataBind();
   }

Thanks,
Shinu.
Tags
General Discussions
Asked by
Sanjay Sangal
Top achievements
Rank 1
Answers by
Marin Bratanov
Telerik team
Ritesh
Top achievements
Rank 1
Shinu
Top achievements
Rank 2
Share this question
or