select after the selectedText

Richmond Mathewson richmondmathewson at gmail.com
Wed Jul 6 03:47:08 EDT 2011


On 07/06/2011 10:38 AM, Mark Wieder wrote:
> Richmond-
>
> Wednesday, July 6, 2011, 12:19:41 AM, you wrote:
>
>> I have just tried this:
>> on mouseUp
>>      set the useUnicode to true
>>      set the unicodeText of the selectedText to numToChar(2340)
>>     select after char -1 of field X
>> end mouseUp
> Untested, but what about
>
> on mouseUp
>    local tChunkChar, tChunkField
>
>    set the useUnicode to true
>    put word 4 of the selectedChunk into tChunkChar
>    put word -1 of the selectedChunk into tChunkField
>    set the unicodeText of the selectedText to numToChar(2340)
>    select after char tChunkChar of field tChunkField
> end mouseUp
>

A good thought; however, there is NO selectedChunk insofar as
the end-user starts his/her edit with a selectedText that is NOT a 
chunk, just
a cursor insertion point.

Just tried it and it threw this:

execution at line 5116 (Chunk: no such object), char 12






More information about the use-livecode mailing list