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

Radwindow AutoSize issue

6 Answers 289 Views
Window
This is a migrated thread and some comments may be shown as answers.
Izak
Top achievements
Rank 1
Izak asked on 24 Aug 2010, 02:27 PM
Hi,

Whenever I use the radwindow to display a page with autosize="true" it always adds extra space to the right and bottom. Please see the attachement. The white part in the window is the content, the light grey is the excess space added. Its does this with all my pages, big and small. The amount of extra space is also variant.

I have tried changing the doctype definition to:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

I also tried adding this css to my pages:
body, form, html
 {
     height: 100%;
     margin: 0px;
     padding: 0px;
 }

Im using 2009.3.1208.35

Any suggestions?

Izak.

6 Answers, 1 is accepted

Sort by
0
Georgi Tunev
Telerik team
answered on 25 Aug 2010, 11:14 AM
Hi Izak,

It looks like you have some global CSS on the parent or the content page that interferes with the RadWindow control. To be able to help however, we need to have a better view over your exact setup. Please open a support ticket and send us a sample project that reproduces the problem so we can investigate further.

Kind regards,
Georgi Tunev
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Chris
Top achievements
Rank 1
answered on 27 Oct 2010, 04:11 PM
Were you able to find the issue? I'm having a similar problem.
0
Fiko
Telerik team
answered on 02 Nov 2010, 09:36 AM
Hello Chris,

The problem comes from some global CSS settings that override the RadWindow's ones. This is why, could you please open a new support ticket and send us the page which causes the problem? We will check it and do our best to provide a working solution as soon as possible.

Sincerely yours,
Fiko
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Larry Brindise
Top achievements
Rank 1
answered on 05 Nov 2010, 04:37 PM
I have a smilar problem.  I have two user controls (I'll call them UC1 and UC2) that live on the same page.  They call the exact same method that creates a 3rd user control that is an encapsulated RadWindow (I'll call this UC3).  When UC1 calls the method to instantiate UC3 and open a page (I'll cal this FORM1) with AutoSize = true, it does indeed autosize.  However when UC2 calls the method to instantiate UC3 and opens the same page (Form1) with AutoSize = true, it does not autosize.  Also, When UC2 instantiates UC3, hardcoded Height and Width parameters are also ignored.

By the volume of postings, It is apparent this "AutoSize" property is causing a lot of people problems due to many limitations like cross-domain scripting and CSS inheritance confusion.  I haven't seen any good direction from Telerik on this topic.  All the answers seem to contain a Demo Site that works, with a request to the person who posted the issue to upload a sample that is broken.  Usually demo sites are helpful for example situations, but not debugging.  My project is huge with several-system-dependencies that are not easily reproducible.  I don't know that I could create a sample that demonstrates this issue.  If I could do that, then I'd implicitly have to know the cause of the problem to reproduce it.

I'm pretty sure the cross-domain scripting issue doesn't apply to my scenario since all of these are on the same site.  Is there a process I can go through to determine why the page won't "AutoSize".  Very frustrating to say the least.  Much to my project manager's unhappiness, I've wasted a few hours on this.

Thanks,
Larry
0
Georgi Tunev
Telerik team
answered on 09 Nov 2010, 01:12 PM
Hello Larry,

I just answered your support ticket on the same subject. For convenience I am pasting part of my reply below:



Regarding the autosize functionality, certain issues (like in cross-domain scenarios) cannot be avoided - to be able to size the window properly, the autosize logic, needs to know what is the size of the content page. The browser security however, will not allow this if the content is coming from a different domain. Such restriction is expected and if we've had a way to work around it, it would be a major security hole as once you get access to the window object in such content page, you could basically do anything with it.

The description of your problem however, leads me to believe that the problem is not related to the AutoSize functionality at all, because you say that even the Width and Height properties that you have set, do not affect the Window that you open. A  problem like this, can occur if you have more than 1 RadWindowManager on the page. In such case, you need to take into consideration the following:

   1. All RadWindowManager's functions (radopen, radalert, radconfirm, radprompt, GetRadWindowManager, etc) are always using the first rendered RadWindowManager on the page.
   2. Every RadWindowManager "knows" only the RadWindows that are declared in its Windows collection.

This means that if you have a RadWindow2 declared in RadWindowManager2, and you use something like radopen(myUrl, "RadWindow2");, radopen will use RadWindowManager1 and will open a new RadWindow with the settings taken from RadWindowManager1. To avoid that problem, when you have multiple managers on a page, you need to get a reference to the correct RadWindowManager first and then call its methods.
e.g.
var manager = $find("<%= RadWindowManager2.ClientID %>");
manager.open(myUrl, "RadWindow2");


I hope this information helps. If you still experience problems or believe that the reason for them is different that the one I described above, please try to isolate a sample project that you could send us. This blog post can help you in this task:
http://blogs.telerik.com/supportdept/posts/10-09-29/isolating_a_problem_in_a_sample_project.aspx



All the best,
Georgi Tunev
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Danny
Top achievements
Rank 1
answered on 26 May 2011, 07:39 PM
I ran into similar problems and found that as a workaround I could use the RadWindowManager's MaxWidth and MaxHeight settings to limit my RadWindow to the desired size.
Tags
Window
Asked by
Izak
Top achievements
Rank 1
Answers by
Georgi Tunev
Telerik team
Chris
Top achievements
Rank 1
Fiko
Telerik team
Larry Brindise
Top achievements
Rank 1
Danny
Top achievements
Rank 1
Share this question
or