Drag and Drop Data
Jeanne A. E. DeVoto
revolution at jaedworks.com
Wed Jun 28 23:14:10 EDT 2006
At 4:28 PM -0700 6/28/2006, Robert Sneidar wrote:
>Here's a brain buster for you. Let's say I want to drag an email
>from Apple Mail and drop it onto a field. Normally nothing happens,
>even though the field gets focused. Is there any way to find out
>anything about the object being dropped onto the field? THAT would
>be cool. If you could create hot links to files or other drag and
>drop objects, like URL's and such, that would be mega cool. Can
>anyone say project manager with linked to-do's and contacts?
I don't know whether drag and drop supports anything interesting
except files as yet, but try something like this:
on dragEnter
beep 2
set the acceptDrop to true
end dragEnter
on dragDrop
put the dragData["files"] into myVariable
answer "Dropped:" & return & myVariable -- list of files
end dragDrop
'
You'd probably want to store the filename(s) in a custom property,
perhaps creating an icon or something to let the user click and open
the file.
--
jeanne a. e. devoto ~ revolution at jaedworks.com
http://www.jaedworks.com
More information about the use-livecode
mailing list