Skip to main content

Flash Q 44 Responses

Last post: 8 years, 4 months ago | Thread started: Jan 19, 05, 11:15 p.m.

RespondNew TopicDisable Images

  • ok_not_ok

    Hello

    Is there a faster way of using TextFormat to italicize a portion in the middle of a long dynamically loaded text file?

    I can use trial and error in guessing the beginning and ending index numbers but it's just taking so much time and I have 15 text files to work on.

    Please kind Flash Gurus..help this poor wet puppy... :(

    Thanks!

    Jan 19, 05, 11:15 p.m. – Permalink
  • Beech

    You can use html text. i think its

    yourtext file_txt.htmlText

    next note >add note

    You must be logged in to add a note. Login now or register for an account.

    Cancel
    Dog-earJan 19, 05, 11:44 p.m. – Permalink
  • Beech

    Also make sure you have render as html ticked on the property inspector and then you can add it in your code.

    next note >add note

    You must be logged in to add a note. Login now or register for an account.

    Cancel
    Dog-earJan 19, 05, 11:49 p.m. – Permalink
  • caseyc

    I would say use html tags in the text but it all depends on what you are doing. If you have a specific string in mind here is something to get you started:

    txtstring = "I can make some text italic";
    searchfor = "some text";
    istart = txtstring.indexOf(searchfor);
    iend = istart + searchfor.length;
    trace(txtstring.substring(istart...

    next note >add note

    You must be logged in to add a note. Login now or register for an account.

    Cancel
    Dog-earJan 20, 05, 12:34 a.m. – Permalink
  • ok_not_ok

    Doh!

    of course "my_txt.htmText"

    thanks for the help beech and casey

    next note >add note

    You must be logged in to add a note. Login now or register for an account.

    Cancel
    Dog-earJan 20, 05, 7:21 a.m. – Permalink

Login or Register to respond to this

Skip to main content