function flash (A, L, SRC)
{
document.write('<object id="FlashID" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="'+A+'" height="'+L+'">');
  document.write('<param name="movie" value="'+SRC+'" />');
  document.write('<param name="quality" value="high" />');
  document.write('<param name="wmode" value="transparent" />');
  document.write('<param name="swfversion" value="8.0.35.0" />');
  document.write('<!-- This param tag prompts users with Flash Player 6.0 r65 and higher to download the latest version of Flash Player. Delete it if you don’t want users to see the prompt. --> ');
  document.write('<param name="expressinstall" value="../swf/expressInstall.swf" />');
  document.write('<!-- Next object tag is for non-IE browsers. So hide it from IE using IECC. --> ');
  document.write('<!--[if !IE]>-->');
  document.write('<object type="application/x-shockwave-flash" data="'+SRC+'" width="'+A+'" height="'+L+'">');
    document.write('<!--<![endif]-->');
    document.write('<param name="quality" value="high" />');
    document.write('<param name="wmode" value="transparent" />');
    document.write('<param name="swfversion" value="8.0.35.0" />');
    document.write('<param name="expressinstall" value="../swf/expressInstall.swf" />');
    document.write('<!--[if !IE]>-->');
  document.write('</object>');
  document.write('<!--<![endif]--> ');
document.write('</object>');

}

function AbreDiv(obj, param){	
	
	var div;
	div = obj;
	
	if (document.getElementById(div).style.display == "none")
	{
		document.getElementById(div).style.display = "block";
	}
	else
	{
		document.getElementById(div).style.display = "none";
   	}
 	
}

function Organiza_Casa(Campo,arrpos,teclapres_key,strtext){ 
	if (((arrpos == "/") || (arrpos == ".") || (arrpos == ",") || (arrpos == ":") || (arrpos == " ") || (arrpos == "-")) && !(teclapres_key == 8)){ 
		separador = arrpos 
		masktext = strtext + separador 
		Campo.value = masktext 
	} 
} 

function FormataCampo(Campo,teclapres,mascara){ 
	//pegando o tamanho do texto da caixa de texto com delay de -1 no event 
	//ou seja o caractere que foi digitado não será contado. 
		strtext = Campo.value 
		tamtext = strtext.length 
	//pegando o tamanho da mascara 
		tammask = mascara.length 
	//criando um array para guardar cada caractere da máscara 
		arrmask = new Array(tammask) 
	//jogando os caracteres para o vetor 
		for (var i = 0 ; i < tammask; i++){ 
			arrmask[i] = mascara.slice(i,i+1) 
		} 
	//alert (teclapres.keyCode) 
	//começando o trabalho sujo 
		if (((((arrmask[tamtext] == "#") || (arrmask[tamtext] == "9"))) || (((arrmask[tamtext+1] != "#") || (arrmask[tamtext+1] != "9"))))){ 
			if ((teclapres.keyCode >= 37 && teclapres.keyCode <= 40)||(teclapres.keyCode >= 48 && teclapres.keyCode <= 57)||(teclapres.keyCode >= 96 && teclapres.keyCode <= 105)||(teclapres.keyCode == 8)||(teclapres.keyCode == 9) ||(teclapres.keyCode == 46) ||(teclapres.keyCode == 13)){ 
				Organiza_Casa(Campo,arrmask[tamtext],teclapres.keyCode,strtext) 
			} 
			else{ 
				Detona_Event(Campo,strtext) 
			} 
		} 
		else{
	//Aqui funcionaria a mascara para números mas eu ainda não implementei 
			if ((arrmask[tamtext] == "A")) { 
				charupper = event.valueOf() 
	//charupper = charupper.toUpperCase() 
				Detona_Event(Campo,strtext) 
				masktext = strtext + charupper 
				Campo.value = masktext 
			} 
		} 
	} 
	
function Organiza_Casa(Campo,arrpos,teclapres_key,strtext){ 
	if (((arrpos == "/") || (arrpos == ".") || (arrpos == ",") || (arrpos == ":") || (arrpos == " ") || (arrpos == "-")) && !(teclapres_key == 8)){ 
		separador = arrpos 
		masktext = strtext + separador 
		Campo.value = masktext 
	} 
} 

function Detona_Event(Campo,strtext){ 
	event.returnValue = false 
	if (strtext != "") { 
		Campo.value = strtext 
	} 
} 

