function ConteudoFlash(swf,largura,altura){
	STRFlash = '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="'+largura+'" height="'+altura+'">'
	STRFlash += '<param name="movie" value="../'+swf+'" />'
    STRFlash += '<param name="quality" value="high" />'
    STRFlash += '<param name="wmode" value="transparent" />'
	STRFlash += '<embed src="../'+swf+'" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="'+largura+'" height="'+altura+'" wmode="transparent"></embed>'
	STRFlash += '</object>'
	document.write(STRFlash);
}

function Aguarde(){
	document.getElementById('aguarde').style.display = '';
}

function Aguarde2(Msg){
	if(confirm(Msg)){
		document.getElementById('aguarde').style.display = '';
	}else{
		return false;
	}
}
			
// ******************************************************
// *********** Galeria de imagem ************
// ******************************************************
function VerFoto(Imagem,idFoto){
	document.getElementById(idFoto).src=Imagem
}

function GoURL(URL){
	location.href = URL;
}

// ******************************************************
// *********** Galeria de imagem ************
// ******************************************************
function FocaCampo(Frm,Campo){
	document.Frm.Campo.focus();
}


// ******************************************************
// *********** Envia formulário ************
// ******************************************************
function Envia(Frm){
	document.Frm.submit();
}

// ******************************************************
// *********** Reseta formulário ************
// ******************************************************
function Reset(Frm){
	document.Frm.reset()
}


// ******************************************************
// *********** mostra determinada area ************
// ******************************************************

function Mostra(IdObjeto){
	if (document.all) {if (document.getElementById(IdObjeto).style.display == ''){
		document.getElementById(IdObjeto).style.display = 'none';}
	else {
		document.getElementById(IdObjeto).style.display = '';
		}
	}
}

// ******************************************************
// ******************* ABRE UMA NOVA JANELA POPUP *************
// ******************************************************

function AbreJanela(link,x,y,s,u) {

	var t = (screen.height - y) / 2;
	var e = (screen.width - x) / 2;
	s=1;

	window.open(link,x+y+s,'width=' + x + ',height=' + y + ',scrollbars=' + s + ',toolbar=0,location=0,status=1,menubar=0,resizable=0,left=' + e + ',top=' + t + '');
	if(u==1){
		window.focus();
	}

}

// ******************************************************
// ******************* atualiza página *************
// ******************************************************

function atualiza()
{
window.opener.location.reload();
}

// ******************************************************
// ******************* cancelar *************
// ******************************************************

function cancela(){
	if (confirm('Deseja cancelar esta operação?')==true){
		window.opener.location.reload();
		window.close();
	}
}