?
Solved

Drag And Drop From Windows To A Swing/JFC App?

Posted on 2004-11-05
3
Medium Priority
?
261 Views
Last Modified: 2013-12-14
Hi all,

Quick Question: Does anyone know of a reference/tutorial that I can use for the following:

- I want to drag and drop a File/Folder from Windows Explorer into my Java JFC/Swing app.

Is this even possible using a pure-Java solution?  Or does Drag and Drop in Swing always have to be from one Swing app to another?


Thanks,
Matt
0
Comment
Question by:MattMejaski
  • 2
3 Comments
 
LVL 3

Assisted Solution

by:nesnemis
nesnemis earned 160 total points
ID: 12507388
0
 
LVL 9

Accepted Solution

by:
DrWarezz earned 240 total points
ID: 12507500
Sure, use a JList, you can then drag multiple files onto it, and have them displayed.. this also enables you to remove certain files from the list, etc..

Check out here for more info:

http://codeproject.com/java/dnd.asp?df=100&forumid=792&exp=0&select=121678

These links are also useful:
http://java.sun.com/docs/books/tutorial/uiswing/misc/dnd.html
http://www.javaworld.com/javaworld/jw-08-1999/jw-08-draganddrop.html

Best of luck ":0)
[r.D]
0
 
LVL 9

Expert Comment

by:DrWarezz
ID: 12523009
Ta  :-)
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This was posted to the Netbeans forum a Feb, 2010 and I also sent it to Verisign. Who didn't help much in my struggles to get my application signed. ------------------------- Start The idea here is to target your cell phones with the correct…
Here is a helpful source code for C++ Builder programmers that allows you to manage and manipulate HTML content from C++ code, while also handling HTML events like onclick, onmouseover, ... Some objects defined and used in this source include: …
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.
The viewer will learn how to use and create new code templates in NetBeans IDE 8.0 for Windows.
Suggested Courses
Course of the Month16 days, 7 hours left to enroll

862 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question