LiveCode is the premier environment for creating multi-platform solutions for all major operating systems - Windows, Mac OS X, Linux, the Web, Server environments and Mobile platforms. Brand new to LiveCode? Welcome!
on commandKeyDown pKey
if pKey is "V" then
put the clipboardData["text"] into MonCB
put the length of MonCB into NbCCB
put the selectedchunk into bufCC
put the value of word 2 of bufCC into depC
put the value of word 4 of bufCC into FinC
put last word of bufCC into LeFld
if depC > FinC then
put the length of fld LeFld into NbCfld
else
put FinC-depC+1 into NbCfld
end if
put NbCCB+NbCfld into NbCharsTot
put NbCharsTot
if NbCharsTot > 10 then
beep
else
pass commandKeyDown
end if
else
pass commandKeyDown
end if
end commandKeyDown
on commandKeyDown theKey
put 1000 into myLimit
if theKey is "V" then
put char 1 to (myLimit - number of chars of the text of me) of \
the clipboardData["text"] into the selection
else pass commandKeyDown
end commandKeyDown
I didn't test this script.
Kind regards,
Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode