
function OpenWindow(Url, Nome, Largura, Altura, Posicao, Parametros){
  //Define a posição da janela
  switch (Posicao) {
	case "ES": PosX = 20; PosY = 20; break;
	case "DS": PosX = (screen.availWidth - Largura - 30); PosY = 20; break;
	case "EI": PosX = 20; PosY = (screen.availHeight - Altura - 30); break;
	case "DI": PosX = (screen.availWidth - Largura - 20); PosY = (screen.availHeight - Altura - 30); break;
  	default: PosX = ((screen.availWidth - Largura)/2); PosY = ((screen.availHeight - Altura)/2); break;
  }
  CISWindow=window.open(Url, Nome, Parametros + ",width=" + Largura + ", height=" + Altura + ",left=" + PosX + ",top=" + PosY + ",screenX=" + PosX + ",screenY=" + PosY);
  CISWindow.focus();
}

