double-clickable icon on desktop for java class?


DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 4 of 4

Thread: double-clickable icon on desktop for java class?

  1. #1
    tim Guest

    double-clickable icon on desktop for java class?



    I use JBuilder Foundation on an NT machine to code the examples from two
    java books I'm using.
    Of course, when I want to compile and run a application from within the IDE,
    I simply use the required
    settings/keystrokes dictated by the development software. Likewise, I also
    use the javac and java
    commands from the DOS-prompt when I need to.

    My question is: Can I generate a double-clickable icon on my desktop for
    a simple java class file that contains
    the main() method? Thanks in advance!



  2. #2
    Shayne Guest

    Re: double-clickable icon on desktop for java class?


    Tim,

    The simplest way to do this is to create a batch file in DOS that calls
    the java command on your class file. This is kind of an ugly hack, though,
    and I assume you want a way to build your java class into an executable.
    For this you will need software. Microsoft Visual J++ has an option that
    creates an exe when you compile (JBuilder might have the same option, I don't
    know). There is a program called JET that converts java class files to native
    code executables, but it costs like $800! I've heard that there is a freeware
    program called J2EXE, but I have not yet been able to find it.
    So making the batch file is probably the easiest way if what you want
    is just a way to run a java class from your desktop.

    Shayne

    "tim" <ttrohs27@hotmail.com> wrote:
    >
    >
    >I use JBuilder Foundation on an NT machine to code the examples from two
    >java books I'm using.
    >Of course, when I want to compile and run a application from within the

    IDE,
    >I simply use the required
    >settings/keystrokes dictated by the development software. Likewise, I also
    >use the javac and java
    >commands from the DOS-prompt when I need to.
    >
    >My question is: Can I generate a double-clickable icon on my desktop for
    >a simple java class file that contains
    >the main() method? Thanks in advance!
    >
    >



  3. #3
    Shayne Guest

    Re: double-clickable icon on desktop for java class?


    I just found that shareware program that I mentioned, and one other:

    JAVA2EXE
    http://www.duckware.com/java2exe.html

    JTOEXE
    http://www.bravozulu.com/Products/JToExe/jtoexe.html

    Have fun.

    "Shayne" <soneill@mindspring.com> wrote:
    >
    >Tim,
    >
    > The simplest way to do this is to create a batch file in DOS that calls
    >the java command on your class file. This is kind of an ugly hack, though,
    >and I assume you want a way to build your java class into an executable.
    > For this you will need software. Microsoft Visual J++ has an option that
    >creates an exe when you compile (JBuilder might have the same option, I

    don't
    >know). There is a program called JET that converts java class files to

    native
    >code executables, but it costs like $800! I've heard that there is a freeware
    >program called J2EXE, but I have not yet been able to find it.
    > So making the batch file is probably the easiest way if what you want
    >is just a way to run a java class from your desktop.
    >
    >Shayne
    >
    >"tim" <ttrohs27@hotmail.com> wrote:
    >>
    >>
    >>I use JBuilder Foundation on an NT machine to code the examples from two
    >>java books I'm using.
    >>Of course, when I want to compile and run a application from within the

    >IDE,
    >>I simply use the required
    >>settings/keystrokes dictated by the development software. Likewise, I also
    >>use the javac and java
    >>commands from the DOS-prompt when I need to.
    >>
    >>My question is: Can I generate a double-clickable icon on my desktop for
    >>a simple java class file that contains
    >>the main() method? Thanks in advance!
    >>
    >>

    >



  4. #4
    tim Guest

    Re: double-clickable icon on desktop for java class?


    I found JToExe @ www.bravozulu.com,

    thanks for the help Shayne !!


    "Shayne" <soneill@mindspring.com> wrote:
    >
    >Tim,
    >
    > The simplest way to do this is to create a batch file in DOS that calls
    >the java command on your class file. This is kind of an ugly hack, though,
    >and I assume you want a way to build your java class into an executable.
    > For this you will need software. Microsoft Visual J++ has an option that
    >creates an exe when you compile (JBuilder might have the same option, I

    don't
    >know). There is a program called JET that converts java class files to

    native
    >code executables, but it costs like $800! I've heard that there is a freeware
    >program called J2EXE, but I have not yet been able to find it.
    > So making the batch file is probably the easiest way if what you want
    >is just a way to run a java class from your desktop.
    >
    >Shayne
    >
    >"tim" <ttrohs27@hotmail.com> wrote:
    >>
    >>
    >>I use JBuilder Foundation on an NT machine to code the examples from two
    >>java books I'm using.
    >>Of course, when I want to compile and run a application from within the

    >IDE,
    >>I simply use the required
    >>settings/keystrokes dictated by the development software. Likewise, I also
    >>use the javac and java
    >>commands from the DOS-prompt when I need to.
    >>
    >>My question is: Can I generate a double-clickable icon on my desktop for
    >>a simple java class file that contains
    >>the main() method? Thanks in advance!
    >>
    >>

    >



Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center