Setting Command Prompt Window Size programmatically

Discussion in 'Java' started by Dino Buljubasic, Sep 24, 2004.

  1. Hi,

    How can I set the Command Prompt window size programmatically in Java.
    I am quite new in Java, but would like to be able to set the size of
    Command Prompt (Windows OS) window when main starts before doing
    anything else.

    Thank you
     
    Dino Buljubasic, Sep 24, 2004
    #1
    1. Advertising

  2. Dino Buljubasic

    John Davison Guest

    Dino Buljubasic wrote:

    > Hi,
    >
    > How can I set the Command Prompt window size programmatically in Java.
    > I am quite new in Java, but would like to be able to set the size of
    > Command Prompt (Windows OS) window when main starts before doing
    > anything else.
    >
    > Thank you


    You cannot, not in Java. Inside the normal command shell, you can use

    mode con cols=x
    mode con lines=x

    but I'm not sure how to get Java to do that before it starts executing
    the program.

    This is outside the scope of this newsgroup -- ask around on the
    microsoft newsgroups about it.

    - john
     
    John Davison, Sep 24, 2004
    #2
    1. Advertising

  3. "John Davison" <> schreef in bericht
    news:...
    > Dino Buljubasic wrote:
    >
    > > Hi,
    > >
    > > How can I set the Command Prompt window size programmatically in Java.
    > > I am quite new in Java, but would like to be able to set the size of
    > > Command Prompt (Windows OS) window when main starts before doing
    > > anything else.
    > >
    > > Thank you

    >
    > You cannot, not in Java. Inside the normal command shell, you can use


    c:\windows\system32\cmd.exe /c mode con cols=80 lines=50
     
    Boudewijn Dijkstra, Sep 24, 2004
    #3
  4. Dino Buljubasic

    Rob D Guest

    java.lang.Runtime.exec(String)

    "Dino Buljubasic" <> wrote in message
    news:...
    > Hi,
    >
    > How can I set the Command Prompt window size programmatically in Java.
    > I am quite new in Java, but would like to be able to set the size of
    > Command Prompt (Windows OS) window when main starts before doing
    > anything else.
    >
    > Thank you
     
    Rob D, Sep 25, 2004
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. chrisdude911
    Replies:
    10
    Views:
    135,427
    srk289
    Mar 10, 2009
  2. gaurav kashyap
    Replies:
    2
    Views:
    621
    gaurav kashyap
    Oct 30, 2008
  3. gaurav kashyap
    Replies:
    3
    Views:
    688
    gaurav kashyap
    Oct 31, 2008
  4. Mel
    Replies:
    10
    Views:
    3,128
    Sailaja Appi
    Feb 13, 2009
  5. jodleren

    Getting picture size/setting window size

    jodleren, Feb 14, 2007, in forum: Javascript
    Replies:
    2
    Views:
    159
    jodleren
    Feb 15, 2007
Loading...

Share This Page