﻿function clickIE() {if (document.all) {(message);return false;}} 
function clickNS(e) {if 
(document.layers||(document.getElementById&&!document.all)) { 
if (e.which==2||e.which==3) {(message);return false;}}} 
if (document.layers) 
{document.captureEvents(Event.MOUSEDOWN);document.onmousedown=clickNS;} 
else{document.onmouseup=clickNS;document.oncontextmenu=clickIE;} 
document.oncontextmenu=new Function("return false") 

function openPDF()
{
    popCentered(500, 700, "Vertex_MailingLabel.pdf");
}
function openGrabExtra()
{
    popCentered(400, 300, "GrabExtra.aspx", true);
}
function popCentered(width, height, url, noScroll)
{
    var topPos = (screen.availHeight)/2 - (height/2);
    var leftPos = (screen.availWidth)/2 - (width/2);
    
    if(noScroll)
        var settings = 'width=' + width + ',height=' + height + ',location=no,directories=no,menubar=no,toolbar=no,' +
            'status=no,scrollbars=no,resizable=no,dependent=yes,top=' + topPos + ',left=' + leftPos;
    else
        var settings = 'width=' + width + ',height=' + height + ',location=no,directories=no,menubar=no,toolbar=no,' +
            'status=no,scrollbars=yes,resizable=no,dependent=yes,top=' + topPos + ',left=' + leftPos;
        
    calWindow=open(url,'win2',settings);
    if (calWindow.opener == null) calWindow.opener = self;
    
    return calWindow;
}