Skip to Content
0
Former Member
Jul 31, 2007 at 09:40 AM

CAFFindException - java.lang.NoClassDefFoundError

14 Views

Hello people,

I trying to call a finder method of a EJB generated with CAF. I have created a standard WD DC. The code of my method is below. The name of the method I am calling is findByNivelClasificacion, that throws a CAFFindException. In order to compile the method I have added in the Used DCs of my WD project: /caf/runtime/impl (CAFRuntimeAPI). At runtime the error is java.lang.NoClassDefFoundError: com/sap/caf/rt/exception/CAFFindException. I also put sap.com/cafruntimeimpl</b> in the section Web Dynpro - Sharing References of my project properties. Dont worked. Can u help me?

public void onActionEnviar(com.sap.tc.webdynpro.progmodel.api.IWDCustomEvent wdEvent )
  {
    //@@begin onActionEnviar(ServerEvent)

	TeraPlanLocal teraPlanLocal = null;

	IWDMessageManager msgMgr = wdComponentAPI.getMessageManager();

	try {


	Context ctx = new javax.naming.InitialContext();


	TeraPlanLocalHome teraPlanLocalHome = (TeraPlanLocalHome ) ctx.lookup("localejbs/realt.com/TeraPlan/TeraPlan");

	
	teraPlanLocal = teraPlanLocalHome.create();

	ArrayList a = new ArrayList();

	Nodo n = new Nodo();
	
	n = (Nodo)(teraPlanLocal.findByNivelClasificacion(wdContext.currentContextElement().getInput()).get(0));

	wdContext.currentContextElement().setOutput(n.getNombre());


	} catch (CreateException e) {

	msgMgr.reportSuccess(e.getMessage());

	e.printStackTrace();

	} catch (NamingException e) {

	msgMgr.reportException(e.getMessage(), false);

	e.printStackTrace();

	}
	
	catch(Exception e)
	{
		msgMgr.reportException(e.getMessage(), false);

		e.printStackTrace();
		
	}