command line arguments

Using the Java SDK with TextPad

Moderators: AmigoJack, bbadmin, helios, Bob Hansen, MudGuard

Post Reply
Tina Shaner

command line arguments

Post by Tina Shaner »

How do I run a Java application from within Textpad if the application is expecting command line arguments? In other words, how can I RUN this class within TEXTPAD so that I can pass in an argument?

class CommandLineArguments {
public static void main (String args[]) {
System.out.println("args[0] = " + args[0]);
}
}
Jeff Epstein

Re: command line arguments

Post by Jeff Epstein »

After creating a tool to run this, be sure to check "prompt for parameters" within the tool's configuration window.

See Configure menu --> Preferences dialog --> Tools branch --> your tool --> right side of the dialog box
Mark Schnitzius

Re: command line arguments

Post by Mark Schnitzius »

Or, just tack the parameters on the end of the parameters line under Tools | Run, e.g.:

Command: C:\jdk1.3.1\bin\java.exe [or wherever]
Parameters: yourPath.yourClassName param1 param2 param2 ....
Post Reply