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

Datepicker cut off inside window

7 Answers 554 Views
Window
This is a migrated thread and some comments may be shown as answers.
Jon
Top achievements
Rank 1
Jon asked on 25 Feb 2011, 10:21 PM
Hi,

I am using a fairly small RadWindow with two controls, a radtextbox and a raddatepicker.  When the calendar on the datapicker opens it ends up opening larger than the radwindow and as such most of it is hidden.  How do you get the datepicker to lay above the window?  I've tried altering the zindex but it still doesn't appear above the window.

Regards,

Jon

7 Answers, 1 is accepted

Sort by
0
Jon
Top achievements
Rank 1
answered on 01 Mar 2011, 10:41 AM
Hi,

Attached is an image of what happens - hopefully someone can help.

Regards,

Jon
0
Shinu
Top achievements
Rank 2
answered on 01 Mar 2011, 11:34 AM
Hello John,

The RadWindow control is basically an IFRAME and you cannot have DHTML elements lay above that IFRAME. One suggestion is to try the approach used in this demo. There using the OnPopupOpening and OnPopupClosing event handlers of the RadDatePicker control and call the autoSize() method of the window object with a small timeout.

Or if you don't want a fixed width window, you can set the window property AutoSize to True, which will automatically resize the window according to its content page
Thanks,
Shinu.
0
Jon
Top achievements
Rank 1
answered on 01 Mar 2011, 01:19 PM
Hi Shinu,

That's what I feared.

I'm not keen on either approach but instead would prefer to explicitly position the date picker and then manually increase the height of the window.  

How do you go about positioning the popup either relative to the button or preferably as absolute positioning on the form?

Best Regards,

Jon
0
Svetlina Anati
Telerik team
answered on 01 Mar 2011, 02:19 PM
Hello Jon,

 Shinu is right about the IFRAME mode but he forgot to mention that there is another mode of RadWindow - it can be also used with ContentTemplate as shown in the demo below:

http://demos.telerik.com/aspnet-ajax/window/examples/internalcontent/defaultcs.aspx

Your code should be similar to this one:

<telerik:RadWindow ID="UserListDialog" runat="server" >
           <ContentTemplate>
               <telerik:RadDatePicker ID=picker runat=server></telerik:RadDatePicker>


If you want you can put the content directly in the RadWindow instead of in another page - this will allow the datepicker to show outside the RadWindow boundaries since it will be on the same page.

All the best,
Svetlina
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!
0
Jon
Top achievements
Rank 1
answered on 01 Mar 2011, 03:06 PM
Many thanks Svetlina.  I remember seeing this demo before but had never tried it.

This solves the problem and in fact also solves the issue that I had where I envisioned having to have a small ton of extra pages with the express purpose of providing small extra popup form functionality.  Now I just need to create any reusable pages as custom controls rather than separate web pages.

Thank you both for your help on this.

Regards,

Jon
0
Jon
Top achievements
Rank 1
answered on 02 Mar 2011, 05:30 PM
Hi Svetlina,

This works very well but there is one major problem.  Having added this to the main page it works very well BUT now the OnButtonClick event on the RadToolBar on the page doesn't fire.   If I remove the RadTextBoxes from the popup window the OnButtonClick works fine.  Put them back and it doesn't fire.  The OnCLientButtonClicking event for the RadToolBar work in both cases though.

I've found a similar message on the forum but the resolution from the user wasn't a real remedy:
http://www.telerik.com/community/forums/aspnet-ajax/toolbar/radtoolbar-won-t-fire-onbuttonclick-with-usercontrol.aspx

Any thoughts?  Is this a known issue or should I submit a support request?

Regards,

Jon
0
Georgi Tunev
Telerik team
answered on 08 Mar 2011, 09:12 AM
Hello Jon,

I am not sure that the problem in the other forum thread is the same as in your case, but to be able to help, we will need to get a better view over your exact setup and current logic. Please open a support ticket and send us a sample project that reproduces the case so we can investigate further.

Regards,
Georgi Tunev
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!
Tags
Window
Asked by
Jon
Top achievements
Rank 1
Answers by
Jon
Top achievements
Rank 1
Shinu
Top achievements
Rank 2
Svetlina Anati
Telerik team
Georgi Tunev
Telerik team
Share this question
or