Please help!- java.lang.NoClassDefFoundError: lotus/domino/AppletBase

I’m just trying to get an Notes applet to run in MS Explorer on my machine but I’m really stuck on this classpath thing.Please help!

The applet works when run in Notes and when run in the Notes Browser.

I test the applet by doing Design>>>Preview in Notes/Web Browser and I am trying to run everything locally on my machine.

Below is the software I’m using, the error I get, followed by the code and then a list of things that I can remember that I’ve tried from the results I’ve got from searching this forum…

I’m using…

Windows 2000

Notes 6.5.2

Eclipse 3.0.0

Microsoft Explorer 6.0.2800.1106

Java™ Plug-in: Version 1.4.1_07

Java compiler 1.4.1.07

First, here’s my error…

java.lang.NoClassDefFoundError: lotus/domino/AppletBase

at java.lang.ClassLoader.defineClass0(Native Method)

at java.lang.ClassLoader.defineClass(Unknown Source)

at java.security.SecureClassLoader.defineClass(Unknown Source)

at sun.applet.AppletClassLoader.findClass(Unknown Source)

at sun.plugin.security.PluginClassLoader.findClass(Unknown Source)

at java.lang.ClassLoader.loadClass(Unknown Source)

at sun.applet.AppletClassLoader.loadClass(Unknown Source)

at java.lang.ClassLoader.loadClass(Unknown Source)

at sun.applet.AppletClassLoader.loadCode(Unknown Source)

at sun.applet.AppletPanel.createApplet(Unknown Source)

at sun.plugin.AppletViewer.createApplet(Unknown Source)

at sun.applet.AppletPanel.runLoader(Unknown Source)

at sun.applet.AppletPanel.run(Unknown Source)

at java.lang.Thread.run(Unknown Source)

Now, here’s my code for the Notes applet…


import lotus.domino.*;

import java.awt.*;

public class helloApplet3 extends AppletBase {

Session session;

int line = 20;

String screenOutput;



public void notesAppletInit() {

	screenOutput = "notesAppletInit starting";

	try {

	  	 session = openSession();

    }

	catch (NotesException e) {System.out.println("Notes Exception Error Occured"); }

	catch (Exception e)      {System.out.println("Exception Error Occured");	}

}



public void notesAppletStart()

{

	String t = "*** V018 Notes Testing *** ";

	String v;

	System.out.println(t);

	screenOutput = t;

	v = "Empty";

	try {

    	v = "Notes Version: " + session.getNotesVersion();

    }

	catch (NotesException e) {System.out.println("Notes Exception Error Occured 2"); }

	catch (Exception e)      {System.out.println("Exception Error Occured 2");	}

	screenOutput = t + v;

	System.out.println(v);

}

    

public boolean mouseDown( Event e, int x, int y) {

	Graphics g = getGraphics();

	g.drawString( screenOutput,10, line );

	line = line + 20;

	if ( line > 200 ) { line = 20; }

	return true;

}

}


Some of the things I’ve tried…

-using various getSession & openSession syntax including the NotesFactory ones.

-Amending the Class variable in the W2K system settings to include d:\notes;D:/Notes/Data/domino/java/

-Amending the Class variable PATH in the W2K system settings to include d:\notes\Notes.jar;D:/Notes/Data/domino/java/NCSO.jar

-Took out the changes to the changes to PATH and created a class variable called CLASSPATH which contained D:/Notes/Notes.jar;D:/Notes/Data/domino/java/NCSO.jar

-copied the files Notes.Jar & NCSO.Jar to the java directories C:\j2sdk1.4.1\jre\lib and C:\j2sdk1.4.1\lib

  • adding the line ALLOW_NOTES_PACKAGE_APPLETS=1 to my notes.ini file

  • reading the article on Java access to the Domino Objects on the IBM/Notes site.

  • shouting at my computer