How do you make a stand-alone app work without seeing a command window...

I'm new to Java so please forgive the very basic question I'm asking. All the apps I've learned how to make so far cause a command window to appear along with the GUI. How do you keep the command window from showing up?

java ExampleApp
I just discovered using the search for this site. I should know better than to make a post without first using the forum's search. It's just that I had been searching the java tutorials already to no avail as well as using a search engine.
According to the forum here, people have said that you need to create a .jar file. I'll need to look into the specifics. Sounds a bit confusing at first. There was also mention of starting the app like so:
javaw ExampleApp
I'll go try that now! Any other suggestions you may have will be appreciated!
Thanks,
Darren

Similar Messages

  • How do you deploy a stand alone app/game in java

    I have a few questions regarding creating a stand alone app for java.
    1) What is the best way to deploy it? how would I create the exe, etc. I've read that you can create executable jars but this doesn't seem like something that would be user friendly
    2) Is there a way to deploy the game/app with it's own JVM so the hosts machine doesn't have to have it installed? How would I go about doing this?
    3) How would I run the app in full screen? What libraries are available?
    Any other advice/comments welcome.

    @morgair: There are plenty of good reasons for using Java to develop software, even when you only plan on targeting Windows. As good as Java distribution is there is no way to guarantee that they a) have Java installed and more likely b) have the version you target installed. Telling a user that they need to go to a second website in order to download and install more software is a huge turn off.
    Most PC users have no experience with a .jar so when they download it they just don't know what to do (even if all they need to do is double-click just like a .exe). Giving out an executable .jar is another turnoff.
    sarcasteak wrote:
    1) What is the best way to deploy it? how would I create the exe, etc. I've read that you can create executable jars but this doesn't seem like something that would be user friendlyIn terms of the .exe, Java does not create .exe's. There are some java to native compilers that will turn your java code into a natice .exe that will run on it's own or with a bundled library. However they are either old, buggy and badly supported, or extremely expensive (googling Java native compiler should give you some good results). There are also plenty 'java to exe' pieces of software. Rather then compiling the java code to native code they wrap the .jar up inside a .exe. When you run the .exe it unpacks the .jar and runs it. To the user it looks like a .exe, however it's still just an executable jar and still requires Java to be pre-installed on their machine in order to run (although some can offer custom error messages if Java is not found).
    If Java is setup, then executable jars are essentially act the same as exe's. For creating them, if you are using NetBeans then they are already available in the project/dist folder after you build. You can also do it on the command line but I never need to so I don't know how. However as a tutorial [this site looks promising|http://neptune.netcomp.monash.edu.au/javahelp/howto/jar.htm].
    I personally use a small .exe which I built using the D programming language. It reads from a text file in the same directory and executes each line in turn. Typically all the text file contains is 'java -jar MyProg.jar'. This way my .jars for the user looks like a .exe.
    Instead of a .exe you could also use a .bat. There are also some .bat to .exe converters online, although I haven't tried any of them so use at your own risk.
    sarcasteak wrote:
    2) Is there a way to deploy the game/app with it's own JVM so the hosts machine doesn't have to have it installed? How would I go about doing this?Yes, you are allowed to redistribute the Sun Java runtime. Just zip up the JRE on your machine and include it with the app/game. You'll also need to ensure that whatever starts the jar uses your unzipped JRE and not the JRE on their machine. The exe I described above also allows this by having the text file contain something like: './my_jre/bin/java -jar MyProg.jar'.
    But first you should also take a look at the license restrictions, they should be in the JREs directory. For example you must redistribute the complete JRE which is a problem if your app is just a few megabytes (when zipped the runtime is usually over 30mb). There are probably plenty of topics on this forum which already discuss redistribution of the JRE.
    sarcasteak wrote:
    3) How would I run the app in full screen? What libraries are available?If it's an app then it should be approximately:
    JFrame frame = new JFrame();
    frame.setExtendedState(JFrame.MAXIMIZED_BOTH);or;
    JFrame frame = new JFrame();
    frame.setExtendedState(frame.getExtendedState() | JFrame.MAXIMIZED_BOTH);However if you want a proper full screen then you need to use the [Full-Screen exclusive mode|http://java.sun.com/docs/books/tutorial/extra/fullscreen/exclusivemode.html], approximately:
    JFrame frame = new JFrame();
    GraphicsEnvironment.getLocalGraphicsEnvironment().getDefaultScreenDevice().setFullScreenWindow( frame );I've also heard plenty of people recommend using java web-start for desktop java apps. Personally I've never used it, but it's something you might want to research.
    Edited by: jl235 on Jun 22, 2009 3:03 AM

  • How do you create a stand alone application using DAQmx when your application SCXI hardware isn't on the computer I am using to create the application?

    How do you create a stand alone application using DAQmx when your application SCXI hardware isn't on the computer I am using to create the application? The DAQmx assitant won't allow me to create a task with hardware that isn't in my system.

    You will need to have at least the DAQ device in your computer to add the chassis. When you add the chassis, don't auto detect the modules. You will have to add the terminal blocks and tell MAX which SCXI module will be connected to the DAQ device. Just make sure you don't test the chassis, when its not there.
    I hope this helps.
    Joshua

  • How to make a stand alone app?

    I have played aroung with Java fore the last eighteen months or so. I feel a lot more comfortable with it than I used to, and as my confidence grows I am trying to come up with real life situations where my programming could help. Nothing to ambitious but just little apps that other people could use (probably non-programmers at that).
    Up to now I have wrote applets that run in browsers, which serve their purpose, but because of the security restrictions applets have limitations. I have wrote apps and run them from either a DOS prompt or from JPadPro. What I have got used to with the internet downloading little apps that once installed I can simply double click on the desk-top icon and away we go. I was wondering whether java has anything like that to offer? I believe that the Java Web Start is to do with this sort of matter, but everytime I open it my P.C. crashes.
    I am looking for a way to present my apps so that non technical people would use. Any advice would be received gratefully, Dave.

    You can buy programs which will turn your .class file into a .exe file, but the key word is buy. I have yet to find a free one that dosn't put some disclamer up when you run your program. I personally prefer using an excecutable jar to run my stand alone apps. It still requires the JRE to be installed on the client PC but you can just include that with your program and have the user install it on thier PC if they don't already have it on there. For information on making an executable jar, you should search the forums, I remeber seeing a user made tutorial in there somewhere that was very helpful to me. This site also has some tutorials on doing it as well, but somethings in it are not so clear. Good Luck.

  • How do you make your xaml ui look good without being a designer?

    Hi all,
    I am realy stuggeling to make ui's for my softwares to give my users a nice visual experience.
    I started to learn c# and winforms some years ago and i have huge problems to make the switch to xaml.
    Now i pretty much use the pre made templates in visual studio such as the Hub App and i do small modifications.
    How do you non designers handle your ui without hiring a designer?
    Are there any place where you can buy cheap pre made ui templates i can use as a starting point?
    I also followed the course design your ux in blend but i can't say i got the hang of it with just one course.
    Are there more courses or tutorials anyone can recomend me about making ui's in blend?
    Are there any other easier tools to make nice looking xaml ui beside blend? Maybe something not as advanced as blend and more visual drag and drop?
    Any tips,tutorials,courses,websites or any other thing that you used when learning to make a nice xaml ui are more than welcome.

    Hi all,
    I am realy stuggeling to make ui's for my softwares to give my users a nice visual experience.
    I started to learn c# and winforms some years ago and i have huge problems to make the switch to xaml.
    Now i pretty much use the pre made templates in visual studio such as the Hub App and i do small modifications.
    How do you non designers handle your ui without hiring a designer?
    Are there any place where you can buy cheap pre made ui templates i can use as a starting point?
    I also followed the course design your ux in blend but i can't say i got the hang of it with just one course.
    Are there more courses or tutorials anyone can recomend me about making ui's in blend?
    Are there any other easier tools to make nice looking xaml ui beside blend? Maybe something not as advanced as blend and more visual drag and drop?
    Any tips,tutorials,courses,websites or any other thing that you used when learning to make a nice xaml ui are more than welcome.

  • How do you make the fios optimizer tool work?

    I still have the release candidate of windows 7 running on this computer, and every time I use the fios optimizing tool, it never works. I have made sure to use internet explorer in administrative mode, but still. It will say that my computer is now optimized, but whenever I run a speed test (in which I get speeds lower that what I should be getting) it will always say at the bottom next to the red X that I should optimize it to make it faster. How do I make this work?

    Unless they changed it in the last couple of weeks the optimizer won't run on win7.

  • How do you make the background all one color without disturbing the subjects?

    I shot a wedding this past weekend.  Where the bridal party walked in there was an acrhway with christmas lights as the only lights.  It made the background all splotchy.  I have tried the paintbrush tool, but only preset choices, such a textures and such.  Won't help.  I need to work around people and make the background all one color.  I've tried using a vignette, but it made it too dark, and when you lighten the exposure you see all the splotches.  Does anyone have any advice.  I am in a  jam, I want the colors to be uniform for all the bridal party....and not look like someone threw paint on the wall.  HELP PLEASE!
    I'm using Adobe Photoshop Elements 10.

    You'll need to post an example so we can figure out the best way.
    Ken

  • How do you make a loop out a sample without it having any stops?

    I took a part of a song to make it into a sample. I looped it to make it longer for a song. However, there are awkward stops in the song now. How do I take this out?  I already tried trimming the stops out but it just seems that it doesn't work.

    Check this out.
    http://www.adobeforums.com/webx/.3bc12b29
    or just hit repeat on DVD player.

  • How do I make my FireWire/USB Drive work on a Mac and windows computers

    I have an Iomega Fire wire/USB 2.0 Potable hard drive I know that to use the hard drive on Windows the hard drive must be set for both Windows and Mac I forgot where to go on my Mac to do this. Its been a while since I had to do this thanks.

    The drive must be formatted as MS-DOS for it to be seen natively by a windows machine. The problem with this is you are limited to a 2gb file size limit - which can be a real problem with video files.
    There is a PC program called MacDrive that will enable a windows machine to see and access Mac formatted drives. Mac formatted drives do not have the file size limit.
    Good luck,
    x

  • When running a "stand-alone" APP..how do I send midi from Logic?

    Hi all,
    When running a "stand-alone" APP..how do I send midi from Logic?.....Please no IAC stuff it doesn't work.......thanx
    SvK

    using IAC here no problems. works very well.
    you can host your au's in another app such as soundflower or au lab, but you are still going to need to get it to hear midi. you can use physical midi ports with something like a MTP midi interface, and getting the midi by routing the out of one port to the in of another (midi loop) but you have to be careful logic doesn't listen to the same midi signal or everything will jam up (midi feedback).

  • How do you make in app purchase with store credit

    how do you make in app purchase with store credit

    It's automatic, as long as your balance covers the price of the item (including any applicable taxes e.g. state sales tax if you are in the US) then only your account's balance will be charged (if it doesn't cover it then any remainder will be charged to your credit card).

  • HT204266 How do you make app update to not show once it is install?

    How do you make app update from not showing once it is installed?

    You can't delete them.
    It will start dropping the earlier updates after about two weeks (on a first in first out basis)

  • HOW DO YOU MAKE A VIGNETTE AROUND A PHOTO IN PSE 7?

    HOW DO YOU MAKE A VIGNETTE AROUND A PHOTO IN PSE 7?  ALSO, HOW DO  YOU MAKE THE PHOTO KIND OF HAZY LOOKING?  JUST A SLIGHT BIT FOR EFFECT.  THANK YOU FOR YOUR HELP!  

    1966desertrat,
    There are various ways to do this; here is one:
    Open picture file
    Duplicate background layer
    Open new blank layer, and fill with white (Edit>fill>white)
    Drag this layer between the background layer and the background copy layer
    On the top layer, make a selection of the subject by dragging with the Elliptical marquee tool, position it to embrace the subject - can use arrow keys on keyboard to fine-tune
    Go to Select>inverse
    Go to Select>feather>try 25px - experiment for degree of feather
    Hit delete on keyboard
    Go to Select>inverse
    Go to Select>deselect
    To blur, go to Filter>blur>gaussian blur and adjust slider to suit
    Message was edited by: hatstead
    You may like Dreamy Suite software which you can download free. I use the stand-alone version.
    http://www.autofx.com/freeplugins/dreamyphoto.asp?id=7

  • Context Help window is not displaying any information in Stand Alone App

    The context help window displays the vi description, as desired) when running in the development environment.  However after building the Stand Alone app, while the I can open the context help window using Ctl-H or the front panel  menu Help , the help window in empty.  The mouse cursor changes to a "hand" while hovering over the icon pic in the upper right hand corner of the Front Panel but does not invoke any change in the help window.
    I am using the same PC for development and check out of the Stand Alone app.
    Any ideas out there?
    Mike

    Mike,
    Yes, you should be able to zip it or just change the extension and we can change it back. In the mean time I have replicated what you are talking about with a simple executable. However, I think this might be expected behavior. After all, your executable is not a VI anymore. You can also make a product suggestion to have this changed.
    Regards,
    Hillary E
    National Instruments

  • How do you make more albums in photo

    How do you make more albums in photo

    There are third party apps that allow you to organize your photos into folders with sub folders right on the iPad. One that I know of is called Photo-Sort for iPad.

Maybe you are looking for