Friday, September 28, 2012

Force a Window to go Full Screen in CRM

Well close to it anyway

For those people who have the their forms setup with four columns across, this piece of script will expand the record pop up to the full height and width of the screen. This isn't quite full screen, but pretty close.

function OnLoad() {
    top.window.moveTo(0, 0);
    if (document.all) {
        top.window.resizeTo(screen.availWidth, screen.availHeight);
    } else if (document.layers || document.getElementById) {
        if (top.window.outerHeight < screen.availHeight ||
           top.window.outerWidth < screen.availWidth) {
            top.window.outerHeight = screen.availHeight;
            top.window.outerWidth = screen.availWidth;
        }
    }
}
Based on KB287171