Código :
function anima_banner(XMLObj){ var container:MovieClip = this.__mc.bholder.fotos; var viewer:GetImage = new GetImage(container, 137, 98, 0xFFFFFF); var titulo2:TextField = this.__mc.bholder.btit_txt img = XMLObj.childNodes[1].childNodes[4].firstChild.nodeValue; trace(img) t1 = XMLObj.childNodes[1].attributes.titulo_esp trace(t1) //titulo2.text = t1 //this.__mc.bholder.btit_txt.text = t1 var my_fmt:TextFormat = titulo2.getTextFormat(); for (var prop in my_fmt) { trace(prop+": "+my_fmt[prop]); } foto = path_fotos+img viewer.loadImage(foto); /*titulo_txt.text = "de" trace("t "+tmp.text) */ } function crea(XMLObj){ //trace(XMLObj) var b_mc = this.__mc.createEmptyMovieClip(("bholder"), this.__mc.getNextHighestDepth()); b_mc._x = 43 b_mc._y = 184 var f_mc = b_mc.createEmptyMovieClip(("fotos"), b_mc.getNextHighestDepth()); f_mc._x = 125 f_mc._y = 0 var titulo_txt = b_mc.createTextField("btit_txt",b_mc.getNextHighestDepth(),0,0,125,31); var my_fmt_ti:TextFormat = new TextFormat(); my_fmt_ti.color = 0x000000; my_fmt_ti.font = "Futura LT Condensed"; my_fmt_ti.align = "right" my_fmt_ti.size = 23 titulo_txt.embedFonts = true; titulo_txt.text = "a" titulo_txt.autoSize = false; titulo_txt.variable = "titulo"; titulo_txt.type = "dynamic"; titulo_txt.setTextFormat(my_fmt_ti); var texto_txt = b_mc.createTextField("btex_txt",b_mc.getNextHighestDepth(),0,31,125,45); var my_fmt_te:TextFormat = new TextFormat(); my_fmt_te.color = 0x000000; my_fmt_te.font = "Futura LT Book"; my_fmt_te.align = "right" my_fmt_te.size = 12 texto_txt.embedFonts = true; texto_txt.text = "b" texto_txt.autoSize = false; texto_txt.variable = "texto"; texto_txt.type = "dynamic"; texto_txt.setTextFormat(my_fmt_te); var fecha_txt = b_mc.createTextField("bfec_txt"+i,b_mc.getNextHighestDepth(),0,76,125,17); var my_fmt_fe:TextFormat = new TextFormat(); my_fmt_fe.color = 0x000000; my_fmt_fe.font = "Futura LT Book"; my_fmt_fe.align = "right" my_fmt_fe.size = 10 fecha_txt.embedFonts = true; fecha_txt.text = "c" fecha_txt.autoSize = false; fecha_txt.variable = "fecha"; fecha_txt.type = "dynamic"; fecha_txt.setTextFormat(my_fmt_fe); this.anima_banner(XMLObj) }
tengo un prolbema con este codigo que eh hecho...
el chiste es que leo un xml sin problema voy y creo unos movieclips y dentro de uno de esos movieclips creo 3 campos de texto y les asigno el valor de a, b y c pues si no le sasigno nada como que se pierden...
luego voy digamos a parsear el xml para mandarle sus valores verdaderos y cuando trato de referenciarlos y ponerle el valor simplemente no aparece el valor.. desaparece la letra y pierde el formato que tenia el cmapo de texto.
alguien podria decirme que estoy haciendo mal??
gracias