Comunidad de diseño web y desarrollo en internet online

createTextField y XML desesperado ya

Citar            
MensajeEscrito el 19 Ene 2006 11:00 am
Muy buenas:

Quiero desarrollar esta parte de carga que siempre hago pero de una manera más "pensada", pero solo me encuentro con problemas. Este es el original, aunque no funciona ya probe a sustituir el xml por texto en los campos y no obtengo nada como htmlText :( alguien me puede decir que estoy haciendo mal? (ya consulte ayuda de flash y varias cosas mas).

XML

Código :

<?xml version="1.0" encoding="utf-8"?>
<root>
   <campodetexto><![CDATA[<p>designestylish<br>sensual<br>organic<br>Intelligent<br>contemporary.....<br><br>Scandinavian</p>]]></campodetexto>
   <campodetexto><![CDATA[<p>Brge<br>Mogensen<br>Finn Juhl<br>Hans Wegner<br>Arne Jacobsen<br>Poul Kjrholm<br>Poul Henningsen<br>Verner Panton</p>]]></campodetexto>
</root>

Actionscript

Código :

stop();
my_XML = new XML();
my_XML.ignoreWhite = true;
my_XML.onLoad = function(success) {
   if (success) {
      mostrarXML();
   }
   else {
      trace("Error loading XML");
   }
}
my_XML.load("xml/textos.xml");
function mostrarXML():Void {
   // creo el formato
   var formato:TextFormat = new TextFormat("Frutiger75-Black", 11, 0xADA194, true);
   var formato2:TextFormat = new TextFormat("Frutiger75-Black", 11, 0xD7BCBB, true);
   // creo los campos de texto
   createTextField("texto", getNextHighestDepth, 0, 0, "", "");
   texto.html = true;
   texto.multiline = true;
   texto.autoSize = true;
   texto.embedFonts = true;
   texto.setTextFormat(formato);
   texto.htmlText = my_XML.firstChild.childNodes[0].firstChild.nodeValue;
   createTextField("texto2", getNextHighestDepth, 0, 245, "", "");
   texto2.html = true;
   texto2.multiline = true;
   texto2.autoSize = true;
   texto2.embedFonts = true;
   texto2.setTextFormat(formato2);
   texto2.htmlText = my_XML.firstChild.childNodes[1].firstChild.nodeValue;
}

Por frenadoll

922 de clabLevel

6 tutoriales

Genero:Masculino  

Barcelona

firefox
Citar            
MensajeEscrito el 19 Ene 2006 11:46 am

Código :

createTextField("texto", 1, 10, 10, 500, 200);
with (texto) {
   text = "tu txt";
}

Espero te sirva :)

Por Naujfract

124 de clabLevel



 

Bogotá Colombia

firefox
Citar            
MensajeEscrito el 19 Ene 2006 01:19 pm
Gracias, esta base me ayudo finalmente a resolverlo ;)

Por frenadoll

922 de clabLevel

6 tutoriales

Genero:Masculino  

Barcelona

firefox
Citar            
MensajeEscrito el 19 Ene 2006 01:24 pm
^^

Por Naujfract

124 de clabLevel



 

Bogotá Colombia

firefox

 

Cristalab BabyBlue v4 + V4 © 2011 Cristalab
Powered by ClabEngines v4, HTML5, love and ponies.