Shell - Java compile code
JB
sundown at pacifier.com
Wed Jun 28 20:13:06 EDT 2017
To compile Java code do the following;
1. Open a text editor and paste the Java code
below:
public class ArgExample {
public static void main(String[] args) {
for(int i = 0; i < args.length; i++) {
System.out.println(args[i] + " is arg " + (i+1));
}
}
}
Save the file on Desktop as ArgExample.java
Make sure you save it as Plain Text.
After you saved it make sure the filename has
the extension ,java such as ArgExample.java
2. Open the Terminal app and type:
cd ~/desktop
javac ArgExample.java
After it has been compiled it will appear
on the desktop as ArgExample.class.
That is the file you call in Livecode.
JB
More information about the use-livecode
mailing list