Ver Mensaje Individual
  #1 (permalink)  
Antiguo 21/11/2006, 13:38
index000
 
Fecha de Ingreso: febrero-2005
Mensajes: 183
Antigüedad: 19 años, 2 meses
Puntos: 0
Exclamación substring no me funciona en xml

hola tengo el siguiente codigo, el mismo lo programe yo, lo q hago aqui es hace un poco mas dinamico y modificable el tema de levantar xml por medio de flash

Código:
readxml = new XML();
linkx = _root.levanto_xml;
//if(largo_modulos_xml){}
alto_modulo = Math.ceil(content_mc.modulo_mc._height);
readxml.load(linkx);
readxml.ignoreWhite = true;
System.useCodepage = true;
readxml.onLoad = function() {
	cantidad_nodos_xml = this.firstChild.childNodes.length;
	//Cuento nodos y duplico mc
	for (i=0; i<cantidad_nodos_xml; i++) {
		//trace((i+1));
		content_mc.modulo_mc.duplicateMovieClip("modulo"+i, 10+i);
		ref_nuevo_modulo = content_mc["modulo"+i];
		ref_nuevo_modulo._y = i*(alto_modulo+off_set);
		ref_nuevo_modulo.info1_txt.html = true;
		//ref_nuevo_modulo.info1_txt.autoSize = "center";
		ref_nuevo_modulo.info1_txt.multiline = true;
		//Firma
		ref_nuevo_modulo.info2_txt.htmlText = this.firstChild.childNodes[i].childNodes[0];
		//Text
		ref_text_info = this.firstChild.childNodes[i].childNodes[1];
		//ref_nuevo_modulo.info1_txt.htmlText = ref_text_info;
		ref_nuevo_modulo.info1_txt.htmlText = ref_text_info;
		trace(ref_nuevo_modulo.firstChild.childNodes[i].childNodes[0].childNodes[1]);
		//////////////.substring(0, 9)
		/*content_mc.onPress = function() {
		getURL(link2, "_parent");
		};*/
	}
};
Problema: Text es una variable q contiene grandes cantidades de texto, usando .substring(0, 19) eso lo solucionaria, pero lo pongo en ref_text_info (por ejemplo) pero no hace nada, como puedo solucionar el tema de cortar texto? muchas gracias.