var ventana;
var conven=0;
var titdef="Laboratorios Smart";
function AbrePopup(cual,titulo)
{
	if(conven==1)
	{
		ventana.close();
		ventana=null;
	}
	if(titulo==null)
	{
		titulo=titdef;
	}
	ventana=window.open('','ventana','resizable=no,scrollbars=no');
	ventana.document.write('<html><head><title>' + titulo + '</title></head><body style="overflow:hidden" marginwidth="0" marginheight="0" topmargin="0" bottommargin="0" leftmargin="0" rightmargin="0" scroll="no" onUnload="opener.cont=0"><img src="' + cual + '" onLoad="opener.Redim(this.width, this.height)">');
	ventana.document.close();
	conven++;
}
function Redim(ancho,alto)
{
	ventana.resizeTo(ancho,alto);
	ventana.moveTo((screen.width-ancho)/2,(screen.height-alto)/2);
}
// Funcion para abrir ventana en tamaņo maximo
function Maximiza()
{
	resizeTo(screen.width,screen.height);
	moveTo(0,0);
}
// Funcion para hacer menu de salto
function MenuSalto(menu)
{
	window.location.href=menu.options[menu.selectedIndex].value;
}
// Funcion para hacer texto vertical
function TexVer(texto)
{
	cont=0;
	while (cont<texto.length)
	{
		letra=texto.substring(cont,cont+1);
		document.write(letra+"<br>");
		cont+=1;
	}
}
// Funcion para cerrar ventana
function Cerrar()
{
	var ventana=window.self;
	ventana.opener=window.self;
	ventana.close();
}
// Funcion para centrar el popup
function Centrar()
{
	iz=(screen.width-document.body.clientWidth) /2;
	de=(screen.height-document.body.clientHeight) /2;
	moveTo(iz,de);
}
