CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 4 of 4
  1. #1
    Join Date
    Dec 2000
    Posts
    43

    run java app w/o dos box

    How do I run a java swing application (ie. >java MyApp) without showing the DOS box window?

    Thanks.



  2. #2
    dlorde is offline Elite Member Power Poster
    Join Date
    Aug 1999
    Location
    UK
    Posts
    10,163

    Re: run java app w/o dos box

    One simple way is to write a batch file for your application and run it from a shortcut. Make a text file called MyApplication.bat in your application directory and put the execution command inside, e.g. java MyApplication

    Now create a shortcut on the desktop (or in the taskbar menus) setting the target to your batch, the start folder to your application folder, and change the run type from normal window to minimized.

    When this shortcut is triggered it will run your application in a minimized DOS box.

    Dave


    To email me remove '_spamjam' from my email address
    Please use [CODE]...your code here...[/CODE] tags when posting code. If you get an error, please post the full error message and stack trace, if present.

  3. #3
    Join Date
    Sep 1999
    Location
    Madurai , TamilNadu , INDIA
    Posts
    1,024

    Re: run java app w/o dos box


    How about using javaw.exe ?

    javaw.exe will not create the DOS window.

    > javaw MyApp


  4. #4
    dlorde is offline Elite Member Power Poster
    Join Date
    Aug 1999
    Location
    UK
    Posts
    10,163

    Re: run java app w/o dos box

    Yep, that's even better! (I forgot about that one ;-)

    Dave


    To email me remove '_spamjam' from my email address
    Please use [CODE]...your code here...[/CODE] tags when posting code. If you get an error, please post the full error message and stack trace, if present.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured