Limit text input based upon its height and width (part 2)

William de Smet wdesmet at
Fri Sep 22 13:13:38 EDT 2006

Hi there,

Well, it's hard to admit but I had the 'don't wrap' of fld "tekst"
activated in the inspector
and therefore it didn't work.

After deselecting  'Don't wrap' the formattedHeight script doesn't
work anymore so textinput is still not limited to the height of the

I still don't get it!


William de Smet

2006/9/22, William de Smet <wdesmet at>:
> Hi there,
> I just tested the earlier suggested code and it works.
> But what if I want to limit text input based upon its height and width?
> I just thought to replace the word 'height' with 'width' and put in
> extra code but that doesn't work:
>  if (the formattedHeight of field "tekst" < the height of field "tekst")
>  then pass keyDown
>  if (the formattedWidth of field "tekst" < the width of field "tekst")
>  then pass keyDown
> Any suggestions?
> William
> (I posted this question a few days ago but I think it got lost somewhere)

Herman Broerenschool
2612 SP Delft

More information about the Use-livecode mailing list