i think 'renderMe' does not qualify as a typical javabean method. I think you should stick to the get/set/is paradigm:
public class TestBean{
String a = "test";
public String getA(){
return(a);
}
public boolean getRenderMe(){
return(true);
}
}
and after this access the values using:
#{testBean.renderMe} or #{testBean.a}
of coarse the name of the bean you are referring to needs to be defined in the faces config.
regards,
-P
the method
On 11/21/05, Elam Daly <[EMAIL PROTECTED]> wrote:
Howdy all,
I'm trying to do something very simple. I have an <outputText> component set as <outputText value="Here I am" rendered="#{TestBean.renderMe}" />
The TestBean is simple as well:
public class TestBean {
int i = 0;
public boolean renderMe() {
if( i%2 == 0 ) return true;
else return false;
}
}
I'm just trying to set the render state programmaticly, yet Tomcat keeps throwing this:javax.faces.FacesException: Bean: com.whiteware.beans.TestBean, property: rendStatusIn fact, if I try to use any bean method at all, it always fails. Even something as simple as 'return true' etc.
org.apache.myfaces.context.servlet.ServletExternalContextImpl.dispatch(ServletExternalContextImpl.java:422)
org.apache.myfaces.application.jsp.JspViewHandlerImpl.renderView
(JspViewHandlerImpl.java:234)
org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:373)
javax.faces.webapp.FacesServlet.service(FacesServlet.java:107)
org.apache.myfaces.component.html.util.ExtensionsFilter.doFilter
(ExtensionsFilter.java:123)
Any help would be appreciated,
Elam

