Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8031323
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 5, 20262026-06-05T01:04:08+00:00 2026-06-05T01:04:08+00:00

I have a basic, simple and maybe stupid question, but how do I implement

  • 0

I have a basic, simple and maybe stupid question, but how do I implement that I can drag a file onto my java program and open it?
I searched really long for this basic question…..

As long as I found out you can’t implement dragging it onto the .jar, because its not executable. You have to create a .exe, which also open your .jar, but that’s all! I would really like to know how 🙂

A keyword would be enough, if I can get the answer through searching this keyword.

Thanks, Leander

//Edit: I may have expressed things a little bit complicated.
Later i want to have a shortcut on, for example, the desktop where i can drag any file on the shortcut and the programm opens with the file(it will, at this point) only move it to a special location.

I don´t know how the code for this would be, I even don’t know how to google for this (I only get questions how to implement “open with” with the answer Desktop.open(File f)).

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-05T01:04:09+00:00Added an answer on June 5, 2026 at 1:04 am

    The place to start reading is the JDK 6 documentation on Drag and Drop. Or else you can start directly with the Drag and Drop tutorials.

    If you want to create a desktop icon that will open your app when you drop a file on it, this depends on the OS. I think that Launch4j will support this, although I haven’t used it in this way.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

This is probably a basic html/css question... I have a simple one-button form that
Maybe this is very basic, but I am all confused. I have a simple
I have a basic question, in the Django template language how can you tell
I have some problems with a very simple yacc/lex program. I have maybe forgotten
Imagine I have a class that represents a simple washing machine. It can perform
I'm working on a simple program that uses OpenSSL to do basic RSA encryption
I have a simple text reading code for Visual Basic: Dim fileReader As String
We have created a simple wix project for a basic windows application. Everything builds
I have a basic class that derived subclasses inherit from, it carries the basic
I have the basic code to rewrite a subdomain to another page. But how

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.