¿Cuántos personajes en mi campo de texto - En mi scrollingText

  • bmcc81
  • Newbie
  • Newbie
  • Avatar de Usuario
  • Registrado: May 07, 2008
  • Mensajes: 9
  • Status: Offline

Nota Mayo 8th, 2008, 1:16 pm

Hola,

Im tratando de aprender cómo encontrar el número de caracteres en un campo de texto y luego hacer una declaración, si fuera de él.

Miré hacia arriba TextField.textWidth y su dice indica la anchura del texto.
Bueno Im no seguro si eso lo que lo que quiero.

Básicamente quiero usar para averiguar el número de caracteres en mi campo de texto para que pueda detener a un texto con desplazamiento.

Código: [ Select ]
function resetPosition() {
    if (trackInfo._width>=15) {
        if (_root.firstload == true) {
            trackInfo._x = 50;
            _root.firstload = false;
        }
    } else {
        trackInfo._x = 112-(trackInfo._width/2);
    }
}

this.onEnterFrame = function() {
    if (this.trackInfo._width>=15) {
        if ((this.trackInfo._x+this.trackInfo._width)<0) {
            this.trackInfo._x = 145;
        } else {
            this.trackInfo._x--;
        }
    }
};
  1. function resetPosition() {
  2.     if (trackInfo._width>=15) {
  3.         if (_root.firstload == true) {
  4.             trackInfo._x = 50;
  5.             _root.firstload = false;
  6.         }
  7.     } else {
  8.         trackInfo._x = 112-(trackInfo._width/2);
  9.     }
  10. }
  11. this.onEnterFrame = function() {
  12.     if (this.trackInfo._width>=15) {
  13.         if ((this.trackInfo._x+this.trackInfo._width)<0) {
  14.             this.trackInfo._x = 145;
  15.         } else {
  16.             this.trackInfo._x--;
  17.         }
  18.     }
  19. };


¿Cuál sería la manera correcta de hacer las descubrir cómo muchos personajes del campo de texto?
Gracias
  • Anonymous
  • Bot
  • No Avatar
  • Registrado: 25 Feb 2008
  • Mensajes: ?
  • Loc: Ozzuland
  • Status: Online

Nota Mayo 8th, 2008, 1:16 pm

  • bmcc81
  • Newbie
  • Newbie
  • Avatar de Usuario
  • Registrado: May 07, 2008
  • Mensajes: 9
  • Status: Offline

Nota Mayo 8th, 2008, 11:30 pm

o simplemente...

¿Cómo puedo saber ni leer, ¿cuántos caracteres en mi campo de texto?

Que se señale en byXML?

Publicar Información

  • Total de mensajes en este tema: 2 mensajes
  • Usuarios navegando por este Foro: No hay usuarios registrados visitando el Foro y 75 invitados
  • No puede abrir nuevos temas en este Foro
  • No puede responder a temas en este Foro
  • No puede editar sus mensajes en este Foro
  • No puede borrar sus mensajes en este Foro
  • No puede enviar adjuntos en este Foro
 
 

© 2011 Unmelted, LLC. Ozzu® es una marca registrada de Unmelted, LLC