Page 1 of 1

How to drag and drop files from a text field

Posted: Fri Feb 19, 2010 9:42 pm
by LESTROSO
Hy to everybody, my problem is i don't know the code to to drag and drop files from a text field, or better from a list of directory files i want to pick one and then drag from my app to desktop. Can you help me?????
I thank you in advance.........bye, lestroso :roll:

Re: How to drag and drop files from a text field

Posted: Mon Feb 22, 2010 3:34 pm
by dunbarx
Not exactly sure what you need.

If I hilite some text in a normal (not a list) field, I can drag it to the desktop and it appears there as a clipping (Mac OS). Not sure if this is useful to you, but you need no code. If you have a list field, you cannot drag and drop at all (I think).

Re: How to drag and drop files from a text field

Posted: Mon Feb 22, 2010 3:40 pm
by Klaus
Hi lestroso,

this will work with a list field with pathnames (e.g. "/Users/klaus/Desktop/Bilder Net/cd.gif" in my test) in it.
Script of list field:

Code: Select all

on dragstart
  set the dragdata["files"] to (the selectedtext of me)
end dragstart
You get the picture :)


Best

Klaus

Re: How to drag and drop files from a text field

Posted: Fri Feb 26, 2010 12:20 am
by LESTROSO
Thank you very much KLAUS!!!!! You have guess my idea, it works very well ,i thank you so much again, i'm sorry if i answer just now but i have had to work.Now i'm making a turbosearch......

cheeers :D :D lestroso

http://www.fasasoftware.com
http://www.myspace.com/lestroso