I've run across a minor glitch with setting window height/width in ie7 and wondering if anyone can assist.
We have a ChangePage function that basically opens a new radwindow to a specified URL or changes the url of the radwindow that is currently open if one exists. I need the window to shrink to the 'aov' size if it comes from another location where the window is larger. This appears to work fine in FF and IE8, but in IE7 it is shrinking the height, but not the width. If I then click the refresh button on the radwindow, it will resize properly...but won't be centered.
We have a ChangePage function that basically opens a new radwindow to a specified URL or changes the url of the radwindow that is currently open if one exists. I need the window to shrink to the 'aov' size if it comes from another location where the window is larger. This appears to work fine in FF and IE8, but in IE7 it is shrinking the height, but not the width. If I then click the refresh button on the radwindow, it will resize properly...but won't be centered.
function ChangePage(FileName, qty) |
{ |
if (window.frameElement) { |
// Redirect |
GetRadWindow().SetUrl(FileName); |
var curWidth = GetRadWindow().get_width(); |
// Coming from Pers to AOV - shrink window |
if (curWidth > 700 && FileName.indexOf("aov") > -1) { |
GetRadWindow().set_width(645); |
GetRadWindow().set_height(600); |
GetRadWindow().center(); |
} |
// Coming from AOV to Pers - expand window |
if (curWidth < 700 && FileName.indexOf("aov") == -1) { |
GetRadWindow().set_width(1000); |
GetRadWindow().set_height(850); |
GetRadWindow().center(); |
} |
} else { |
// Going to AOV or Pers check |
if(FileName.indexOf("aov") > -1) { |
openRadWindow(FileName,600,645,1,0,1,1,qty); |
} else { |
openRadWindow(FileName,850,1000,1,0,1,1,qty); |
} |
} |
} |
function GetRadWindow() |
{ |
var oWindow = null; |
if (window.radWindow) oWindow = window.radWindow; |
else if (window.frameElement.radWindow) oWindow = window.frameElement.radWindow; |
oWindow.SetModal(true); |
return oWindow; |
} |