struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Eric Seynaeve <eseyna...@abis.be>
Subject Accessing static field using EL
Date Fri, 20 Feb 2004 09:25:24 GMT
I have problems accessing a static field using the Struts Expression Language.
The goal is to put the names of all the form bean instance names, ... in static
String fields and use those fields throughout as much files as possible. This to
eliminate frantic debugging sessions due to typo's <g>.

This is a code snippet:
public class SessionNumberForm extends AbisDynaActionForm {
	public static final String SESSION_NUMBER = "sessionNr";

	...
}

Here I try to access the field:
<html:text property="${SessionNumberForm.SESSION_NUMBER}" />

but it gives following error:
[ServletException in:/WEB-INF/tiles/index.jsp] No getter method for property
${SessionNumberForm.SESSION_NUMBER} of bean org.apache.struts.taglib.html.BEAN'

How could this field be accessed?

Thanks,

Eric


---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org


Mime
View raw message