ClassNotFoundException for packaged bean

I'm getting a ClassNotFoundException when trying to instantiate a packaged bean from a jsp file. When the class itself is placed in the WEB-INF\classes directory of the web module, it loads and runs without error. Here's the code I'm using:
[Bean - C:\Code\java\jsp\WEB-INF\classes\com\custompackages\TestBean.java]
package com.custombeans;
public class TestBean {
int counter;
compiles to C:\Code\java\jsp\WEB-INF\classes\com\custompackages\TestBean.class
[JSP - C:\Code\java\jsp\WEB-INF]
<%page import="com.custombeans.TestBean"%>
CLASSPATH=...;C:\Code\java\jsp\WEB-INF\classes;C:\Code\java\jsp\WEB-INF\classes\com\custompackages;
I can't seem to track down the problem even though it may be obvious.
Any help would be great !
Cheers

yes, in your bean code change package com.custombeans; to package com.custompackages;Then in your jsp code change <%page import="com.custombeans.TestBean"%> to <%page import="com.custompackages.TestBean"%>[/ or alternativley if you want to load it into the session scope use <jsp:useBean id="TestBean" scope="session" class="com.custompackages.TestBean" />If you use the import command you have to create an instance
<% TestBean myBean = new TestBean(); %>if you use the jsp:useBean tag it creates and instance for you and gives it the name you passed for the id. So above I used "TestBean". <% TestBean.yourFunctionCall(); %>-S-

Similar Messages

  • Do JNDI look up for entity beans from a session bean  in different  jars

    I have a problem doing entity beans JNDI look up from a session bean which is deployed
    as a separate package (session.jar) from the entity beans (entity.jar)
    I believe if both session bean and entity beans are deployed into one jar and
    I specify ejb-local-reference-description for session bean, it should work. However,
    due to some reason, they have to be in separated packages but still in the same
    container. Then question how to do JNDI lookup given entity beans only have local
    interfaces?
    FYI.
    1 both session.jar and entity.jar are self-contained. i.e., no deployment error.
    each JNDI name can be viewed from JNDI tree
    2. weblogic-ejb-jar.xml for session.jar
    <weblogic-ejb-jar>
    <description><![CDATA[Generated by XDoclet]]></description>
    <weblogic-enterprise-bean>
    <ejb-name>PetstoreLogic</ejb-name>
    <stateless-session-descriptor>
    </stateless-session-descriptor>
    <reference-descriptor>
    </reference-descriptor>
    <jndi-name>PetstoreLogic</jndi-name>
    <local-jndi-name>PetstoreLogicLocal</local-jndi-name>
    </weblogic-enterprise-bean>
    </weblogic-ejb-jar>
    3. weblogic-ejb-jar.xml (code snip) for entity.jar
    <weblogic-enterprise-bean>
    <ejb-name>Account</ejb-name>
    <entity-descriptor>
    <persistence>
    <persistence-type>
    <type-identifier>WebLogic_CMP_RDBMS</type-identifier>
    <type-version>6.0</type-version>
    <type-storage>META-INF/weblogic-cmp-rdbms-jar.xml</type-storage>
    </persistence-type>
    <persistence-use>
    <type-identifier>WebLogic_CMP_RDBMS</type-identifier>
    <type-version>6.0</type-version>
    </persistence-use>
    </persistence>
    </entity-descriptor>
    <reference-descriptor>
    </reference-descriptor>
    <local-jndi-name>net.sourceforge.cpetstore/AccountLocalHome</local-jndi-name>
    </weblogic-enterprise-bean>
    4. if I do
    accountLocalHome = (AccountLocalHome) ic.lookup("net/sourceforge/cpetstore/AccountLocalHome");
    get error like:
    javax.naming.LinkException: . Root exception is javax.naming.NameNotFoundException:
    While trying to look up /app/ejb/net.sourceforge.cpetstore-entity.jar#Account/local-home
    in /app/ejb/cpetstore-ejb.jar#PetstoreLogic.; remaining name '/app/ejb/net/sourceforge/cpetstore-entity/jar#Account/local-home'
         at weblogic.jndi.internal.BasicNamingNode.newNameNotFoundException(BasicNamingNode.java:869)
         at weblogic.jndi.internal.ApplicationNamingNode.lookup(ApplicationNamingNode.java:150)
         at weblogic.jndi.internal.WLContextImpl.lookup(WLContextImpl.java:338)

    In weblogic-ejb-jar.xml use jndi-name instead of local-jndi-name in reference-descriptor
    element.
    "Qiming He" <[email protected]> wrote:
    >
    I have a problem doing entity beans JNDI look up from a session bean
    which is deployed
    as a separate package (session.jar) from the entity beans (entity.jar)
    I believe if both session bean and entity beans are deployed into one
    jar and
    I specify ejb-local-reference-description for session bean, it should
    work. However,
    due to some reason, they have to be in separated packages but still in
    the same
    container. Then question how to do JNDI lookup given entity beans only
    have local
    interfaces?
    FYI.
    1 both session.jar and entity.jar are self-contained. i.e., no deployment
    error.
    each JNDI name can be viewed from JNDI tree
    2. weblogic-ejb-jar.xml for session.jar
    <weblogic-ejb-jar>
    <description><![CDATA[Generated by XDoclet]]></description>
    <weblogic-enterprise-bean>
    <ejb-name>PetstoreLogic</ejb-name>
    <stateless-session-descriptor>
    </stateless-session-descriptor>
    <reference-descriptor>
    </reference-descriptor>
    <jndi-name>PetstoreLogic</jndi-name>
    <local-jndi-name>PetstoreLogicLocal</local-jndi-name>
    </weblogic-enterprise-bean>
    </weblogic-ejb-jar>
    3. weblogic-ejb-jar.xml (code snip) for entity.jar
    <weblogic-enterprise-bean>
    <ejb-name>Account</ejb-name>
    <entity-descriptor>
    <persistence>
    <persistence-type>
    <type-identifier>WebLogic_CMP_RDBMS</type-identifier>
    <type-version>6.0</type-version>
    <type-storage>META-INF/weblogic-cmp-rdbms-jar.xml</type-storage>
    </persistence-type>
    <persistence-use>
    <type-identifier>WebLogic_CMP_RDBMS</type-identifier>
    <type-version>6.0</type-version>
    </persistence-use>
    </persistence>
    </entity-descriptor>
    <reference-descriptor>
    </reference-descriptor>
    <local-jndi-name>net.sourceforge.cpetstore/AccountLocalHome</local-jndi-name>
    </weblogic-enterprise-bean>
    4. if I do
    accountLocalHome = (AccountLocalHome) ic.lookup("net/sourceforge/cpetstore/AccountLocalHome");
    get error like:
    javax.naming.LinkException: . Root exception is javax.naming.NameNotFoundException:
    While trying to look up /app/ejb/net.sourceforge.cpetstore-entity.jar#Account/local-home
    in /app/ejb/cpetstore-ejb.jar#PetstoreLogic.; remaining name '/app/ejb/net/sourceforge/cpetstore-entity/jar#Account/local-home'
         at weblogic.jndi.internal.BasicNamingNode.newNameNotFoundException(BasicNamingNode.java:869)
         at weblogic.jndi.internal.ApplicationNamingNode.lookup(ApplicationNamingNode.java:150)
         at weblogic.jndi.internal.WLContextImpl.lookup(WLContextImpl.java:338)

  • How to setup classpath for the beans?

    My packaged beans reference classes in other jars. Right now I have to set up the classpath in the Windows user variables. I think that is not a good way.
    Is there a better way to do it? Thanks.
    Anthony

    Matthew,
    Thanks for the advice. Unfortunately the way you sugguested will not work for me because the beans bridge stuff is just a small piece of the system that I will deploy. And I can't ask all the needed jars put into the Java plug-in's directory.
    I know there is another way to setup the classpath just for the plug-in's. It is by using the Java Plug-in's console. But this looks work only in a development environment. I don't know how I can automate it as part of a product installation process.
    I will deploy an enterpise applicaiton. So far I haven't found a better way to set the classpath than setting the environment variables (which is kind of rude).
    Anthony

  • Context lost for Session Beans

    Hi Guys,
    Using WLS4.5.1 sp13 on NT4 sp6.
    We are having a problem with the Context of a Session Bean switching from the correct user to the last person who logged in. The users credentials and hence the context filter through from the JSP pages correctly and the Session Bean is created correctly.
    Then when someone else logs in, both users assume the identity of the new user. The context of the EJB's being used changes to the new user for all other users.
    When we do a getInitialContext() we assume the "weblogic.security.acl.Security.getCurrentUser()" properties to create the context. Either this is getting switched somehow or we are getting a circular reference to a Session Bean which is confusing weblogic.
    One thing we do do is after various actions, we change the context to a new user and create a new EJB to validate against this users properties. When finished we throw this EJB away - and resume "presumably" in the original context !?!?!?
    Any ideas ??!!?!?
    Thankx in advance,
    Andrew Harris//

    I'm not sure if it is possible in 6.0, but 6.1 definitely supports this -
    you can specify deployment order using console.
    "Sébastien Charrier" <[email protected]> wrote:
    Hi,
    I was wondering if it's possible to define a deployement order for session
    beans and if yes how to configure it (where in the console or in the
    config.xml) ? Each session bean is in a single jar file and all the jars are
    packaged in an ear file. I'm using weblogic 6.0 sp2.
    thanks in advance.--
    Dimitri

  • ClassNotFoundException for Spring class

    Hi,
    We are migrating application from WebSphere to SAP NetWeaver. Our Web module uses JAAS for authentication.
    In the custom login module we are using Spring framework. We are creating BeanFactory using:
    [code]BeanFactory beanFactory = new ClassPathXmlApplicationContext ("conf/service-client/client-prop.xml");[/code]
    Content of client-prop.xml is :
    [code]<?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN//EN" "http://www.springframework.org/dtd/spring-beans.dtd">
    <beans>
         <bean id="propertyConfigurer" class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer" >
              <property name="location">
                   <value>conf/service-client/client.properties</value>
              </property>
         </bean>
         <bean id="ClientProperty" class="com.mypkg.common.service.bootstrap.types.ServiceClientProperty">
              <property name="url">
                   <value>$://$:$/$/services</value>
              </property>
              <property name="namespacePrefix">
                   <value>$</value>
              </property>
         </bean>
    </beans>[/code]
    Now we are getting the exception:
    [code]1.5#000FFE10ED0E0043000000030000090C000417A932F6D6B4#1151915378772#com.sap.engine.services.security#sap.com/MyWeb#com.sap.engine.services.security#Guest#2####11191b600a6e11dbca17000ffe10ed0e#SAPEngine_Application_Thread[impl:3]_35##0#0#Error##Java###Exception #1#com.sap.engine.services.security.exceptions.BaseLoginException: Error in some of the login modules.
         at com.sap.engine.services.security.login.ModulesProcessAction.run(ModulesProcessAction.java:146)
         at java.security.AccessController.doPrivileged(Native Method)
         at com.sap.engine.services.security.login.FastLoginContext.login(FastLoginContext.java:152)
         at com.sap.engine.system.SystemLoginModule.login(SystemLoginModule.java:90)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:324)
         at javax.security.auth.login.LoginContext.invoke(LoginContext.java:675)
         at javax.security.auth.login.LoginContext.access$000(LoginContext.java:129)
         at javax.security.auth.login.LoginContext$4.run(LoginContext.java:610)
         at java.security.AccessController.doPrivileged(Native Method)
         at javax.security.auth.login.LoginContext.invokeModule(LoginContext.java:607)
         at javax.security.auth.login.LoginContext.login(LoginContext.java:534)
         at com.mypkg.client.security.actions.LoginAction.executeLogic(LoginAction.java:43)
         at com.mypkg.client.framework.action.Action.execute(Action.java:67)
         at com.mypkg.client.framework.action.Action.execute(Action.java:41)
         at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:431)
         at com.mypkg.client.framework.action.RequestProcessor.processActionPerform(RequestProcessor.java:53)
         at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:236)
         at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1196)
         at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:432)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.runServlet(HttpHandlerImpl.java:385)
         at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.handleRequest(HttpHandlerImpl.java:263)
         at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:340)
         at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:318)
         at com.sap.engine.services.httpserver.server.RequestAnalizer.invokeWebContainer(RequestAnalizer.java:821)
         at com.sap.engine.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:239)
         at com.sap.engine.services.httpserver.server.Client.handle(Client.java:92)
         at com.sap.engine.services.httpserver.server.Processor.request(Processor.java:147)
         at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:37)
         at com.sap.engine.core.cluster.impl6.session.UnorderedChannel$MessageRunner.run(UnorderedChannel.java:71)
         at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
         at java.security.AccessController.doPrivileged(Native Method)
         at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:94)
         at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:162)
    Caused by: java.lang.ExceptionInInitializerError
         at com.mypkg.common.service.client.ServiceClientFactory.getProxy(ServiceClientFactory.java:131)
         at com.mypkg.common.service.client.ServiceClientFactory.getService(ServiceClientFactory.java:56)
         at com.mypkg.client.security.auth.UPServiceLoginModule.login(UPServiceLoginModule.java:101)
         at com.sap.engine.services.security.login.ModulesProcessAction.run(ModulesProcessAction.java:68)
         ... 37 more
    Caused by: org.springframework.beans.factory.BeanDefinitionStoreException: Error registering bean with name 'propertyConfigurer' defined in class path resource [conf/service-client/client-prop.xml]: Bean class [org.springframework.beans.factory.config.PropertyPlaceholderConfigurer] not found; nested exception is com.sap.engine.frame.core.load.SAPClassNotFoundException: org.springframework.beans.factory.config.PropertyPlaceholderConfigurer
         at org.springframework.beans.factory.xml.DefaultXmlBeanDefinitionParser.parseBeanDefinitionElement(DefaultXmlBeanDefinitionParser.java:428)
         at org.springframework.beans.factory.xml.DefaultXmlBeanDefinitionParser.parseBeanDefinitionElement(DefaultXmlBeanDefinitionParser.java:335)
         at org.springframework.beans.factory.xml.DefaultXmlBeanDefinitionParser.parseBeanDefinitions(DefaultXmlBeanDefinitionParser.java:266)
         at org.springframework.beans.factory.xml.DefaultXmlBeanDefinitionParser.registerBeanDefinitions(DefaultXmlBeanDefinitionParser.java:186)
         at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.registerBeanDefinitions(XmlBeanDefinitionReader.java:238)
         at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:155)
         at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:124)
         at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:140)
         at org.springframework.context.support.AbstractXmlApplicationContext.loadBeanDefinitions(AbstractXmlApplicationContext.java:103)
         at org.springframework.context.support.AbstractXmlApplicationContext.loadBeanDefinitions(AbstractXmlApplicationContext.java:71)
         at org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory(AbstractRefreshableApplicationContext.java:87)
         at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:267)
         at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:80)
         at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:65)
         at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:56)
         at com.mypkg.common.service.bootstrap.BootstrapServiceClient.getClientProperty(BootstrapServiceClient.java:119)
         at com.mypkg.common.service.bootstrap.BootstrapServiceClient.<init>(BootstrapServiceClient.java:48)
         at com.mypkg.common.service.bootstrap.BootstrapServiceClient.<clinit>(BootstrapServiceClient.java:39)
         ... 41 more
    Caused by: java.lang.ClassNotFoundException: org.springframework.beans.factory.config.PropertyPlaceholderConfigurer
    Loader Info -
    ClassLoader name: [common:library:com.sap.security.api.sda;library:com.sap.security.core.sda;library:security.class;library:webservices_lib;service:com.sap.security.core.ume.service;service:connector;service:dbpool;service:keystore;service:security;service:userstore]
    Parent loader name: [Frame ClassLoader]
    References:
       library:com.sap.ip.basecomps
       library:core_lib
       common:library:IAIKSecurity;library:activation;library:mail;library:tcsecssl
       library:servlet
       library:sapxmltoolkit
       library:com.sap.mw.jco
       library:com.sap.util.monitor.jarm
       library:j2eeca
       library:opensql
       interface:security
       interface:log
       interface:shell
       interface:keystore_api
       library:ejb20
       interface:webservices
       library:com.sap.guid
       interface:appcontext
       interface:endpoint_api
       interface:resourceset_api
       interface:resourcecontext_api
       common:service:iiop;service:naming;service:p4;service:ts
       interface:ejbcomponent
       interface:container
       interface:visual_administration
       interface:transactionext
       interface:dsr_ejbcontext_api
       service:timeout
       service:memory
       service:deploy
       library:antlr
       library:jdbdictionary
       library:opensqlextensions
       service:adminadapter
       interface:cross
    Resources:
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    ext
    com.sap.security.api.sda
    com.sap.security.api.perm.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    services
    keystore
    keystore.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    ext
    security.class
    tc_sec_saml_service_api.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    ext
    webservices_lib
    jaxm-api.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    services
    connector
    connectorimpl.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    ext
    com.sap.security.api.sda
    com.sap.security.api.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    services
    com.sap.security.core.ume.service
    com.sap.security.core.ume.service.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    ext
    com.sap.security.core.sda
    com.sap.security.core.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    ext
    security.class
    tc_sec_jaas_test.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    ext
    security.class
    tc_sec_saml_jaas.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    ext
    webservices_lib
    webservices_lib.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    services
    userstore
    userstore.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    ext
    com.sap.security.core.sda
    com.sap.security.core.tpd.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    ext
    security.class
    tc_sec_https.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    ext
    security.class
    tc_sec_saml_xmlbind.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    services
    dbpool
    sqljimpl.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    services
    security
    security.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    ext
    security.class
    tc_sec_ssf.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    services
    dbpool
    opensqllib.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    ext
    security.class
    tc_sec_jaas.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    services
    dbpool
    dbpool.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    ext
    security.class
    tc_sec_compat.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    ext
    security.class
    tc_sec_saml_toolkit_api.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    ext
    webservices_lib
    jaxrpc-api.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    ext
    security.class
    tc_sec_saml_toolkit_core.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    ext
    security.class
    tc_sec_userstore_lib.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    ext
    webservices_lib
    saaj-api.jar
       E:
    usr
    sap
    J2E
    JC00
    j2ee
    cluster
    server0
    bin
    ext
    security.class
    tc_sec_saml_util.jar
    Loading model: {parent,local,references}
         at com.sap.engine.frame.core.load.ReferencedLoader.loadClass(ReferencedLoader.java:314)
         at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302)
         at java.lang.Class.forName0(Native Method)
         at java.lang.Class.forName(Class.java:219)
         at org.springframework.util.ClassUtils.forName(ClassUtils.java:87)
         at org.springframework.beans.factory.support.BeanDefinitionReaderUtils.createBeanDefinition(BeanDefinitionReaderUtils.java:64)
         at org.springframework.beans.factory.xml.DefaultXmlBeanDefinitionParser.parseBeanDefinitionElement(DefaultXmlBeanDefinitionParser.java:369)
         ... 58 more[/code]
    ClassNotFoundException exception is coming for the class: org.springframework.beans.factory.config.PropertyPlaceholderConfigurer but the correponding jar file (spring-beans.jar) exists in the WEB-INF/lib.
    Any kind of help will be greatly appreciated.
    Regards,
    Sagar

    Apparently, this question was repeated 3 times in different forums and is answered in the link below:
    ClassNotFoundException for Spring class
    Regards.

  • STRUTS - Cannot retrieve definition for form bean null -aaaarrrrgh

    Hi Folks,
    my head hurts and i become crazy... i know that a lot of people asked this question before, but i did not found any suitable solution.
    I have simple a jsp page, containing a form which should be handled by struts. I tried everything, but i did not found my mistake.
    Can anyone help me please?
    JSP:
    <%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean"%>
    <%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html"%>
    <%@ page contentType="text/html;charset=windows-1252"%>
    <html:html locale="true">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
    <title>Anmeldung f?r GOLEM Quickplayout</title>
    </head>
    <body>
    <html:errors/>
    <html:form action="checkLogin.do">
      <table cellspacing="3" cellpadding="2" border="0" width="100%" align="left">
        <tr>
          <td>
            <bean:message key="prompt.username"/>
          </td>
          <td>
            <html:text property="username"/>
          </td>
        </tr>
        <tr>
          <td>
            <bean:message key="prompt.password"/>
          </td>
          <td>
            <html:text property="password"/>
          </td>
        </tr>
      </table>
    </html:form>i tryed a lot for the FORM -Tag, for instance:
    <html:form action="checkLogin.do"> or
    <html:form action="/checkLogin.do"> or
    <html:form action="/checkLogin"> but all throws the same exception. :(
    struts-config.xml
      <form-beans>
        <form-bean name="loginForm" type="de.orb.quick.view.LoginForm"/>
      </form-beans>
      <action-mappings>
      <action path="/login" type="de.orb.quick.view.LoginAction" name="loginForm" input="/login.jsp" scope="session" unknown="true">
        <forward name="success" path="/showData.jsp"/>
      </action>
        <action path="/checkLogin" type="de.orb.quick.view.CheckLogonAction" unknown="false" input="/login.jsp">
          <forward name="success" path="/storeRequestData.do"/>
          <forward name="failure" path="/login.do"/>
        </action>
    Exception:
    javax.servlet.jsp.JspException: Cannot retrieve definition for form bean null
         at org.apache.struts.taglib.html.FormTag.lookup(FormTag.java:831)
         at org.apache.struts.taglib.html.FormTag.doStartTag(FormTag.java:506)
         at _login._jspService(login.jsp:11)     [/login.jsp]
    LoginAction:
      public ActionForward execute(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException {
        return mapping.findForward("success");
    LoginForm:
    public class LoginForm extends ActionForm  {
      private String password = "";
      private String username = "";
      public void reset(ActionMapping mapping, HttpServletRequest request) {
        super.reset(mapping, request);
      public ActionErrors validate(ActionMapping mapping, HttpServletRequest request) {
        return super.validate(mapping, request);
      public String getPassword() {
        return password;
      public void setPassword(String password) {
        this.password = password;
      public String getUsername() {
        return username;
      public void setUsername(String username) {
        this.username = username;
      }Sorry for this stupid question, but how can i avoid this exception while using struts TagLibs?
    I tried to face the jsp with another action, but this does not change anything.
    Thank you in advance
    Mirko

    javax.servlet.jsp.JspException: Cannot retrieve definition for form bean myfrom
         at org.apache.struts.taglib.html.FormTag.lookup(FormTag.java:831)
         at org.apache.struts.taglib.html.FormTag.doStartTag(FormTag.java:506)
         at jsp_servlet.__index._jspService(__index.java:155)
         at weblogic.servlet.jsp.JspBase.service(JspBase.java:33)
         at weblogic.servlet.internal.ServletStubImpl$ServletInvocationAction.run(ServletStubImpl.java:1053)
         at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:387)
         at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:305)
         at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:6291)
         at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:317)
         at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:97)
         at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletContext.java:3575)
         at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java:2573)
         at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:178)
         at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:151)

  • Cannot retrieve definition for form bean null

    Hi,
              I have a page jsp which contains a form. This form contains an action
              towards (page.do ).
              I configured struts-config.xml file in whom I put a configuration of
              action ( type=xxx.pageAction ) but not form because I have not need of
              it.
              During the execution it show that it tries to instantiate a bean of form
              corresponding to a configuration of action and post this error message
              " Root causes of ServletException javax.servlet.jsp. JspException:
              Cannot retrieve definition for form bean null "
              Could you indicate to me where is the problem ?
              Here is my configuration :
              < html:form action = " page.do " method = " post " >
              </html:form >
              <action path="/page"
              type="xxx.pageAction">
              <forward name="show" path="/page.jsp"/>
              </action>
              Thanks in advance
              Rachid.
              

    There's little reason to use Struts infrastructure to set this up since you have no model, and the controller aspect is well-defined (just go to "NewProject"!). You're basically providing a link from one page to another, akin to doing an <a href>, and you wouldn't use Struts to do a simple link :).
    I would just just use standard HTML.
    If you're okay with using Javascript, this is the simplest:
    <input type="button" onClick="document.location='NewProject'">
    Or you can use a standard HTML form, as you've basically done already:
    <form action="NewProject" method="get">
    <input type="submit" value="Create">
    </form>

  • Standard Smartform for label printing for packages - pls advice

    Hi All,
    I need help in changing a print program ie Standard Smartform for label printing for packages ?
    Standard Driver program: SDPACKDR
    Please provide me with the detailed steps for editing the Std Smartform according to any requirement.
    Points will be rewarded promptly.
    Thanks.

    hi,
    1. The smartform name is SD_PACK_ETIK.
    2.Just copy the standard program into Zprogram and make chanes and assign in NACE with the form.
    3.But,in smartform lable printing is not possible.
    4.you can print barcodes.
    Regards,
    Kumar(Reward if helpful).

  • Could not find the policy in WMI for package

    Hi,
    I am trying to deploy a language pack to a windows 8.1 machine and it is not installing. According to the execmgr.log it cannot find the policy in WMI? I have tried running the machine policy update within CFG MGR but no change. Is there something else
    I can check?
    <![LOG[Policy is updated for Program: InstallEN, Package: LIA002A0, Advert: LIA2011A]LOG]!><time="09:47:18.345+300" date="01-28-2015" component="execmgr" context="" type="1" thread="980"
    file="execreqmgr.cpp:7063">
    <![LOG[Raising client SDK event for class CCM_Program, instance CCM_Program.PackageID="LIA002A0",ProgramID="InstallEN", actionType 45l, value NULL, user NULL, session 4294967295l, level 0l, verbosity 30l]LOG]!><time="09:47:18.347+300"
    date="01-28-2015" component="execmgr" context="" type="1" thread="980" file="event.cpp:405">
    <![LOG[Mandatory execution requested for program InstallEN and advertisement LIA2011A]LOG]!><time="09:47:19.220+300" date="01-28-2015" component="execmgr" context="" type="1" thread="3684"
    file="execreqmgr.cpp:3527">
    <![LOG[Creating mandatory request for advert LIA2011A, program InstallEN, package LIA002A0]LOG]!><time="09:47:19.220+300" date="01-28-2015" component="execmgr" context="" type="1" thread="3684"
    file="execreqmgr.cpp:3653">
    <![LOG[Could not find the policy in WMI for package LIA002A0 program InstallEN]LOG]!><time="09:47:19.242+300" date="01-28-2015" component="execmgr" context="" type="2" thread="3684" file="softdistpolicy.cpp:2851">
    <![LOG[CreateMandatoryRequestRecursively failed at FindUserOrSystemPolicy InstallEN]LOG]!><time="09:47:19.243+300" date="01-28-2015" component="execmgr" context="" type="2" thread="3684"
    file="execreqmgr.cpp:3670">

    Did you check this
    post?
    It turned out the root cause of the problem was one of the packages that the TS called.  Even though SCCM had been set to use the selected distribution points and said the package was installed on those DPs, it hadn't actually copied the files over.
     Updating to a new source version and ensuring the files copied correctly resolved the issue.  Hopefully SCCM 2012 will do a better job of communicating a dependency problem, but I haven't had a chance to test it yet.
    You can also check this
    post.
    it appears the majority of these messages occur when you have a system that has an expired advertisement still being applied to it. 
    Nick Pilon | Blog : System Center Dudes

  • Goods Receipt for packaging material - Item cat. ELP

    Hi expert,
    I am facing a problem regarding receive Packaging Material Item i MIGO via inbound. Problem detail as below hope you can advise me:
    1. I create PO order 1pc of Throttle
    2. In Inbound Delivery Screen I do Packing for Throttle by using Handling Unit Function, packaging Material is Carton Box.
    3. After Pack complete, Item for packaging material is auto generated in inbound screen:
    - Item Cat. of Throttle = ELN
    - Item Cat. of Carton Box (Packaging Material) = ELP
    4. When i do MIGO via Inbound: there is only 1 item for Throttle is displayed. How to do Goods Receipt for Carton Box item? Do i Miss any setting for that?
    Thanks.

    i thnk u sould maintain material master with two units one is throttle and second is cartoon.
    u shud maintain that how many throttle is equal to 1 cartoon.
    this u can maintain directlt in PO (In condition tab, with these two field : OUN and UN). in PO as a OUN ,give throttle n UN , give cartoon in item overview as well as condition tab.
    and during delivery change the unit in cartoon. then while migo, material will show in cartoon.
    hope it will be helpful.
    Thanks
    Nisha

  • Urgent:Material Type for Packaging Material in WM and MM

    Hi
    There is a place in SPRO where i can define the material type for packaging.
    Logistics - General -> Handling Unit Management -> Basics -> Define Packaging Material Types
    How can i create a material using this material type? What is the use of material type here?
    Whenever i create material in MM01/MM41, i get the standard material type list.
    Thanks & REgards
    Kapil

    Hi,
    In T.code: OMS2, you can get standard material type list.VERP is the standard material type for packing material.You can copy VERP and rename to ur material type( as it is ur business requriement or else u can use same VERP)
    What is the use of material type here?
    With the help of ur Material Type , u can craete material like The material type,will be used while defining the material
    master.At that time,in Tcode:MM01,first screen we need to
    mention,(material type)it show the nature of material
    ex:-engineering product,finished products,semifinished
    product,etc.,
    It also play vital role on material numbering,material type in comination with plant & valuation class, play vital role in inventory & accoputning.
    To Create Material,use t. Code: MM01,
    Step-1
    Enter Material Code: ( example-Polythene Bag, If External Number Range or leave it blnak)
    Enter Industry Sector: ...................
    Enter Material Type: ..........................(VERP- Packing)
    Step-2
    Select
    Views you required( like eample:basic data-1, like basic data-2,purachsing, purchase order text,General plant data, accounting-1, accounting-2 etc)
    Step-3
    Enter Plant,
    Enter Storage location
    {{{Enter Sales organization & Distribution channel(if sales view selected)}}}
    Step-4
    You will have views like (example-1, basic data, enter Base unit of measure, material group and other details as required field,example-2,Accounting data, enter valuation class, price control; S or V & price)
    Step-5
    Save.
    Note: Before creation material you must know which Industry Sector, Material Type ur going to use and material numbering is internal or external.
    For more, check the following link for creation of material
    http://www.synactive.com/docu_e/doc_multi_mm01.html
    Regards,
    Biju K

  • Batch management separately for packaging / fuel material

    Hi experts,
    to be very clear , batch management is activated for all type of materials like raw material and finished goods.
    For packaging material and fuel material i didnt activate batch management.
    my issue is to maintain batch for packaging and fuel material with batch no. separately.
    if any customization or through any exits / badi ?
    i also maintain for stock at  batch level .
    regards
    dks

    Hi,
    If batch is not activated for Material type packaging / fuel material...and stock /PO/GRN/IV exists for those material, then its impossible to to acitivate batches for those materials whose stock /PO/GRN/IV exists ...
    If you want to maintain batches for these material types then you have to reverse all documents and you have to clear all stocks, which will be tedious job.
    Better from future when ever you create new material for those material types, then activate the batch management check box.

  • Errors for PACKAGE BODY WWV_FLOW_CUSTOM_AUTH_SSO

    Hi All,
    Running the below package so I can configure SSO...running into the below error.
    Any help is appreciated
    SQL> @custom_auth_sso_902.plb;
    ...wwv_flow_custom_auth_sso
    Warning: Package Body created with compilation errors.
    Errors for PACKAGE BODY WWV_FLOW_CUSTOM_AUTH_SSO:
    LINE/COL ERROR
    0/0 PL/SQL: Compilation unit analysis terminated
    1/14 PLS-00304: cannot compile body of 'WWV_FLOW_CUSTOM_AUTH_SSO'
    without its specification

    You need to ask Apex related questions in the Apex forum.
    Include the 4 digit Oracle and Apex versions you are using when you post your problem.
    I assume that you have read how to implement SSO for Apex applications to be partner applications for Oracle App Server single sign-on authentication? If not, I suggest that you search http://tahiti.oracle.com for the relevant instructions. (cannot recall the exact manual reference - I did this 3 or 4 years ago myself)

  • Are the fonts installed with the Mac OS OK to use for commercail use? ie, a logo which willbe used for packaging, TV broadcast and internet.

    Are the fonts installed with the Mac OS 10.6 OK to use for commercial use? ie, a logo which willbe used for packaging, TV broadcast and internet.

    srjeffgr wrote:
    Some font foundries require extended licesnes for different uses.
    You're welcome. Again, as mentioned in that discussion, you can use Font Book to check if the foundry has entered any license limitation notices in the font info (Preview > Show Font Info).
    Basically, fonts are code. The copyright applies to the code. If the product you distribute doesn't include the code, then the copyright does not apply to it. That's why embedding has to be dealt with specifically, because embedding fonts in a document means including the code or parts of it in the document.

  • Generate delivery items for packaging materials but aggregate in one line

    Hy, we have a requirement for delivery process, we have WM and we make picking by RF, and automatic generate items for packaging materials, but one line per pallet and the deliveries have a lot of line items that we want to aggregate in only one line item, instead of having for e.g. 30 lines with one pallet we need to have one line item with quantity 30.
    can you help us,
    Thanks in advance.
    jonh

    Hi,
    You can very well achieve this by usinh a spilt routine in your copy control from sales document to delivery document.
    Goto tcode: VOFM - Data transfer - deliveries.
    For this you need to write a routine with the help of  your ABAPer & to include logic something like this:
    You have to identify some unique feild in the two material or even the material code itself.
    Then in the routine logic, you pass this feilds in the combination criterai field in delivery that is "ZUKRL"
    Then in copy control sales doc to delivery: you attach this routine in header details in data transfer "Header Data"
    See the code below for your help:
    SELECT SINGLE PRAT1 PRAT2 PRAT3 PRAT4 PRAT5 INTO (MVKE-PRAT1,MVKE-PRAT2,MVKE-PRAT3,MVKE-PRAT4,MVKE-PRAT5) FROM MVKE
                      WHERE MATNR = CVBAP-MATNR
                      AND   VKORG = CVBAK-VKORG
                      AND   VTWEG = CVBAK-VTWEG.
    IF NOT MVKE-PRAT1 IS INITIAL.
    ZUK1-C+0(1) = 'O'.  "FOR OIL
    *LIKP-ZUKRL = ZUK1.
    ENDIF.
    IF NOT MVKE-PRAT2 IS INITIAL.
    ZUK1-C+0(1) = '1'.  " FOR FRAGILE 1
    *LIKP-ZUKRL = ZUK1.
    ENDIF.
    IF NOT MVKE-PRAT3 IS INITIAL.
    ZUK1-C+0(1) = 'N'.  " FOR NON FRAGILE
    LIKP-ZUKRL = ZUK1.
    ENDIF.
    IF NOT MVKE-PRAT4 IS INITIAL.
    ZUK1-C+0(1) = '2'.  " FOR FRAGILE 2
    LIKP-ZUKRL = ZUK1.
    ENDIF.
    IF NOT MVKE-PRAT5 IS INITIAL.
    ZUK1-C+0(1) = 'B'.  " FOR BULK / OVERWEIGHT
    LIKP-ZUKRL = ZUK1.
    ENDIF.
       LIKP-ZUKRL = ZUK1.
    CONDENSE LIKP-ZUKRL NO-GAPS.
    endif.
    Hope this helps you
    Regards,
    Dhananjay

Maybe you are looking for