on pasteKey strange behaviour?

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!

Moderators: Klaus, FourthWorld, heatherlaine, kevinmiller, robinmiller

Post Reply
nkrontir
Posts: 15
Joined: Wed Apr 12, 2006 3:24 am

on pasteKey strange behaviour?

Post by nkrontir » Wed Nov 15, 2006 3:34 am

Hi.

For some reason, the on pasteKey is giving me grief. I need to check the clipboarddata, and if a condition is true, paste the data and enable a button but revolution ignores me. I even tried:

Code: Select all

on pasteKey
   answer "PASTE"
end pasteKey
but for some reason it acts as if there is no such code.

What am I doing wrong here?

elanorb
Livecode Staff Member
Livecode Staff Member
Posts: 455
Joined: Fri Feb 24, 2006 9:45 am

Post by elanorb » Wed Nov 15, 2006 11:05 am

Hi

The Revolution development environment traps the pasteKey (and cutKey and copyKey) message so it will not be received by a stack running in the development environment but will work in a standalone.

To test your pasteKey handler choose Suspend Development Tools from the Development menu. You should then be able to handle the message.

I hope this helps

Regards

Elanor

nkrontir
Posts: 15
Joined: Wed Apr 12, 2006 3:24 am

Post by nkrontir » Wed Nov 15, 2006 6:43 pm

Makes sense.
I've just realized that this actually exists in the transcript language reference but I had failed to see it as the comments for this are on the next page... :oops:

Thanks for your time.

Post Reply

Return to “Getting Started with LiveCode - Experienced Developers”