Page 1 of 1

Setting text to link

Posted: Thu Feb 02, 2017 8:03 am
by pravgcet
I have a field "ffield" and a button and I am trying to make content of field "link"

Here is my code

In Button code, I have added this :

on mouseUp
set the textStyle of fld "ffield" to "link"
put url "some web address" into ur
set the linkText of fld "ffield" to ur
end mouseUp

This gives me error : Object: can't set this property

Anyone know why?

Re: Setting text to link

Posted: Thu Feb 02, 2017 8:40 am
by Thierry
pravgcet wrote: I have a field "ffield" and a button and I am trying to make content of field "link"
Hi,

You were almost there!

Try this:

Code: Select all

   set the linkText of char 1 to -1 of fld "ffield" to ur
HTH,

Thierry