Basic question about compiling
- From: simplicity <stella_pigeon@xxxxxxx>
- Date: Fri, 10 Feb 2012 08:12:07 -0800 (PST)
I know this is kind of basic but somehow the solution escapes me.
I have the applet which is supposed to hook up with the hardware
attach to the computer. The hook-up interface is available in the
external JAR archive called sbsdk.jar. So, I compile the applet with
the following command:
javac -d %DST% ^
-classpath %CLASSPATH_1%;%CLASSPATH_2% ^
%SRC%\MyApplet.java >%DST%\MyApplet.log 2>%DST%\MyApplet.err
%CLASSPATH_1% points to the location of the sbsdk.jar, namely "C:\Users
%CLASSPATH_2% points to "%JRE%\lib\plugin.jar" (for JSObject to
OK, so far so good. Applet compiles with no issues. But that's where
it ends. When I load the HTML file containing the applet into a
browser I am getting the exception
Exception in thread "thread applet-MyApplet.class-1"
Luckily, I have the access to the sbsdk.jar source code. When I copy
the folder structure containing compiled classes of sbsdk (com\<blah-
blah>\sbsdk), my applet loads and everything works as expected.
Can someone help me understand why this is happening? I know that this
is generally caused by SBSDKListener class not being available at the
run time (while it is available at compile time, hence no build
errors) but I do not understand what it means in practical terms.