I wrote small program. Its useage is setting value1 & value2 after that push Multi button to multiple them.
JSP code is | <%@ page contentType="text/html;charset=WINDOWS-31J" %> | <%@ taglib uri="http://java.sun.com/jsf/core" prefix="f" %> | <%@ taglib uri="http://java.sun.com/jsf/html" prefix="h" %> | | <html> | <head> | <title>Security Check</title> | </head> | <body> | <f:view> | Welcome | <br> | <h:form> | <table> | <tr><td>Value1</td><td><h:inputText value="#{calculator.value1}"/></td></tr> | <tr><td>Value2</td><td><h:inputText value="#{calculator.value2}"/></td></tr> | </table> | <h:commandButton type="submit" value="Multiple" action="#{calculator.multi}"></h:commandButton> | </h:form> | <br><br> | | Answer:<h:outputText value="#{calculator.answer}"/> | </f:view> | | </body> | </html> | Seam code is | package seam.sample; | | import java.io.Serializable; | | import javax.annotation.security.PermitAll; | import javax.annotation.security.RolesAllowed; | import javax.ejb.Stateful; | | import org.jboss.seam.ScopeType; | import org.jboss.seam.annotations.Name; | import org.jboss.seam.annotations.Scope; | | | @Stateful | @Name("calculator") | @Scope(ScopeType.SESSION) | public class CalculatorAction implements Calculator,Serializable { | | int value1 = 0; | int value2 = 0; | int answer = 0; | | public int getAnswer() { | return answer; | } | public void setAnswer(int answer) { | this.answer = answer; | } | public int getValue1() { | return value1; | } | public void setValue1(int value1) { | this.value1 = value1; | } | public int getValue2() { | return value2; | } | public void setValue2(int value2) { | this.value2 = value2; | } | | public CalculatorAction() { | | } | | | //@RolesAllowed("admin") | public void multi() { | System.out.println("**** multi ****"); | answer = value1 * value2; | } | | //@RolesAllowed("user") | public void plus() { | System.out.println("**** plus ****"); | answer = value1 + value2; | } | | //@PermitAll | public void minus() { | System.out.println("**** minus ****"); | answer = value1 - value2; | } | | } | I checked the log. there's DEBUG infomation below | 2006-06-22 09:27:58,119 DEBUG [org.jboss.seam.jsf.SeamVariableResolver] resolving name: calculator | 2006-06-22 09:27:58,119 DEBUG [org.jboss.seam.Component] seam component not found: calculator | 2006-06-22 09:27:58,119 DEBUG [org.jboss.seam.jsf.SeamVariableResolver] resolving name: calculator | 2006-06-22 09:27:58,119 DEBUG [org.jboss.seam.Component] seam component not found: calculator | 2006-06-22 09:27:58,119 DEBUG [org.jboss.seam.jsf.SeamVariableResolver] could not resolve name | 2006-06-22 09:27:58,119 DEBUG [org.jboss.seam.jsf.SeamVariableResolver] could not resolve name | 2006-06-22 09:27:58,119 DEBUG [org.jboss.seam.jsf.SeamVariableResolver] resolving name: calcucator | 2006-06-22 09:27:58,119 DEBUG [org.jboss.seam.Component] seam component not found: calcucator | 2006-06-22 09:27:58,119 DEBUG [org.jboss.seam.jsf.SeamVariableResolver] resolving name: calcucator | 2006-06-22 09:27:58,119 DEBUG [org.jboss.seam.Component] seam component not found: calcucator | 2006-06-22 09:27:58,119 DEBUG [org.jboss.seam.jsf.SeamVariableResolver] could not resolve name | 2006-06-22 09:27:58,119 DEBUG [org.jboss.seam.jsf.SeamVariableResolver] could not resolve name | I don't understand why seam can't find calculator. Deos anyone explain about this? Any kind of suggestion will help me. Susumu View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3952513#3952513 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3952513 All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnk&kid=107521&bid=248729&dat=121642 _______________________________________________ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user