Java to execute command prompt statement

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Sharp

    #1

    Java to execute command prompt statement

    Hi

    I would like to use Java to run the windows command prompt (a program) and
    execute a particular statement (eg. cd\program\...) .
    Is this possible?

    Any help appreciated.

    Cheers
    Michael









    ---
    Outgoing mail is certified Virus Free.
    Checked by AVG anti-virus system (http://www.grisoft.com).
    Version: 6.0.853 / Virus Database: 581 - Release Date: 1/02/2005


  • Sharp

    #2
    Re: Java to execute command prompt statement

    [color=blue]
    > Hi
    >
    > I would like to use Java to run the windows command prompt (a program) and
    > execute a particular statement (eg. cd\program\...) .
    > Is this possible?
    >
    > Any help appreciated.
    >
    > Cheers
    > Michael[/color]

    I found a solution; using Java, create a .BAT file containing the statement
    to execute.
    Is there a better way?

    Cheers
    Michael








    ---
    Outgoing mail is certified Virus Free.
    Checked by AVG anti-virus system (http://www.grisoft.com).
    Version: 6.0.853 / Virus Database: 581 - Release Date: 1/02/2005


    Comment

    Working...