Two Laptop Bag*
The moose likes Swing / AWT / SWT and the fly likes alternative to JFileChooser (panel similar to Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "alternative to JFileChooser (panel similar to "drop the file here")" Watch "alternative to JFileChooser (panel similar to "drop the file here")" New topic
Author

alternative to JFileChooser (panel similar to "drop the file here")

juan perez
Greenhorn

Joined: Feb 05, 2013
Posts: 4
I would like to make a panel, similar to "drop the file here"
Is it possible? Any suggestions?
Sorry for my English.
Randall Twede
Ranch Hand

Joined: Oct 21, 2000
Posts: 4340
    
    2

i am not sure what you mean by "drop the file here"
you can use jfilechooser or the system clipboard


SCJP
Visit my download page
juan perez
Greenhorn

Joined: Feb 05, 2013
Posts: 4
something like this


------------------------------------------------------------------------------------------------



instead of a JFileChooser

Randall Twede wrote:i am not sure what you mean by "drop the file here"
you can use jfilechooser or the system clipboard
Randall Twede
Ranch Hand

Joined: Oct 21, 2000
Posts: 4340
    
    2

i think you mean use the clipboard.
i have just the thing for you.
i found most of it on the internet, i just made it a class.
this is specifically for images, but you can make it work.
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18541
    
    8

And if you don't want the clipboard to be involved, you can still use a similar technique using drag-and-drop. Google for java drag and drop tutorial and check out the Oracle tutorial. Based on the code you find there you should be able to do some experimenting and come up with a component where you can drop a file which was dragged from (e.g.) Windows Explorer.
juan perez
Greenhorn

Joined: Feb 05, 2013
Posts: 4

thank you very much.
Randall Twede tested the code and served me served me.
instead of imageFlavor I tested with javaFileListFlavor.
Paul Clapham thank you very much for your suggestion, I'll try, I think that is what I was looking.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: alternative to JFileChooser (panel similar to "drop the file here")
 
Similar Threads
tag 'select', field 'list', name 'courseName': The requested list key 'Course' could not be resolved
Drop down menu
2.1 French Translation
Need to dynamically add checkBoxes in a GUI
Scrolling BIG Images