3 Replies Latest reply on Jun 11, 2003 4:53 AM by henkmeulekamp

    JSP jetty(jboss-3.2.1)  JSP:setProperty problem with static

    henkmeulekamp Newbie

      i'm having a problem with public static fnal int's from a javabean. If i do this (setting the property via a static final int property on the class:

      <jsp:useBean id="personBean" scope="page" class="com.denkk.jblearning.web.personBean" />
      <jsp:setProperty name="JB_Page" property="required_acces_level" value="<%=com.denkk.jblearning.web.jblearningPage.ACCESS_LEVEL_STUDENT%>" />

      org.apache.jasper.JasperException: argument type mismatch
      at org.apache.jasper.runtime.JspRuntimeLibrary.handleSetProperty(JspRuntimeLibrary.java:547)
      at org.apache.jsp.top_jsp._jspService(top_jsp.java:90)

      Then convert it to this (hardcoded numbers in it), it works..
      <jsp:useBean id="JB_Page" scope="page" class="com.denkk.jblearning.web.jblearningPage" />
      <jsp:setProperty name="JB_Page" property="required_acces_level" value="0" />

      And If i do this it also works:

      <jsp:useBean id="personBean" scope="page" class="com.denkk.jblearning.web.personBean" />

      So there seems to be a problem with setting properties... I have an app, original for Oracle9ias, where it runs fine, which i want to convert to Jboss. Only this is bugging me....

      does anyone know what's going wrong? (also tested it with jboss 3_2_tomcat) same problem there, so it may be the case that i'm doing something wrong.. But why does it work on Oracle9ias then?

      Henk J Meulekamp