HTMLText question

dunbarx at aol.com dunbarx at aol.com
Tue Dec 15 15:33:51 EST 2009


Can I use the HTMLText property in a variable?

In other words, why does this fail with an error?

on mouseup
    get fld "myField" --has a few words in it
    set the htmlText of word 2 of it to "<box>word 2 of it</box>"
    set the htmltext of fld "myField" to it
end mouseup

Only field references allowed?

This seems to indicate that only a literal can be used when setting the 
tags:

on mouseup
    get fld "myField" --has a few words in it
    set the htmlText of word 2 of field "myField" to "<box>word 2 of it<
/box>"
end mouseup

You get "word 2 of it", nicely boxed.

Thanks. I am still a newbie.

Craig Newman



More information about the Use-livecode mailing list