I need some help. I have a radwindow with contenttemplate. i want it to behave like a regular div, or lets say like the jquery ui window where the window height increases LIVE based on html instead of calling autosize or setting width and height on every move.
what i have inside is a radasync upload, when you upload files in async, the list of files uploaded gets appended and a scroll bar appears, instead i want the window size to increase. i know i could use the client side api of radasync upload to trigger window size, but i'm interested in a clean method where the radwindow behaves like a div.
is there a hack to do it? like setting height to auto or to set display as table or something? if not, can telerik introduce such feature? i wanted to use the jquery ui, but to be consistent with the theme and ability to post back / control state from server end, i prefer radwindow.
please let me know if there is a solution.
thanks.
7 Answers, 1 is accepted

You can set AutoSize property of RadWindow as true which gets or sets a value indicating whether the window will automatically resize itself according to its content page or not.
Thanks,
Princy.

As far as I understood from your explanations, the RadWindow autosizes fine when it is initially opened. After that you change the size of the content and the RadWindow stays the same size. This is the correct behavior by design - the RadWindow automatically autosizes when it is opened. To make it autosize again explicitly, you should call its method autoSize when you change the content size. The autoSize method is documented below:
http://www.telerik.com/help/aspnet-ajax/window-programming-radwindow-methods.html
and you can make the make the RadWindow autosize itself with an animation or not, controlling that with an input parameter.
In addition, you can see this in action in our online demo below:
http://demos.telerik.com/aspnet-ajax/window/examples/dialogreturnvalue/defaultcs.aspx
When you open the RadWindow and you show the calendar dropdown, the RadWindow autosizes itself. When the calendar dropdown is hidden, the window autosize back to the changed size.
Please, examine the provided resources and use the suggested approach. In case you still experience problem, please share sample demo page - there is no need to show your actual content, just put the same elements and logic - e.g DIV, random strings, etc since the content information, databases, etc itself is not what matters in the case but the layout configuration.
Svetlina Anati
the Telerik team

I found the solution, by setting the css
.rwWindowContent > div:first-child
{
height: auto !important;
}
.rwTable
{
height: auto !important;
}
but doing this will disable the ability to resize the window. i want the use to be able to resize the window, but it should grow when the contents go beyond the user resized height, so when the user resizes, if radwindow can use that as a min height and if the height property is set to auto, then the issue will be resolved.
You can provide options in the radwindow to set the clientside resize mode.
Do you think this is something telerik might be able to incorporate in their next release?
Did you test my suggestion? It does exactly what you explain - what you should do is to explicitly call autoSize when you change the content (adding DOM elements in your case and showing a calendar dropdown in the demo - it does not matter as far it changes the size of the content).
Since from your last post what I again understand is exactly what I suggest, in case your problem persists, please share fully working sample code with my suggestion implemented and reproduction steps and screenshots of what exactly does not work in this manner. Once I receive this, I will get e better understanding why this approach does not work for you and I will fix it for you.
Svetlina Anati
the Telerik team

yes. I understand and that is that I have been doing in many places, but i have more complex scenarios where the window will get resized by MANY client scripts and i dont want to call it from every spot.
i want a window which can resize itself using css only.
can you add an option to radwindow which will allow this? it should be a fairly simple solution.
RadWindow contains complex HTML and many elements which have different configuration and behavior depending on the features used. If we simply change the CSS to have auto height, this will reflect in features not correctly working (e.g limiting the width and height, restriction zone, etc). If your scenario is a simple one and you can make it work as you require with the mentioned CSS, you can go ahead and override the default styles. However we strongly recommend to use autosize instead because if you change the defaults in that manner you explain, we do not ensure that other features will work correctly and it will be up to you to resolve them with your customizations.
Regards,Svetlina Anati
the Telerik team