struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "sjones" <>
Subject Re: Struggling with html:options
Date Wed, 09 Jul 2003 16:56:11 GMT
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html" %>
<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %>
<%@ page language="java"
 import=", java.util.*"
contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1"

<META http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<META name="GENERATOR" content="IBM WebSphere Studio">
<META http-equiv="Content-Style-Type" content="text/css">

<LINK href="theme/Master.css" rel="stylesheet" type="text/css">

List o = DirectoryEqualityOperator.getOperationNames();
request.setAttribute("yerSelectBox", o);
<html:form action="/">
    <html:select property="srchMethod">
        <html:options collection="yerSelectBox" property="key"
labelProperty="value" />

    <select name="xsrchMethod">
             for (int i=0; i < o.size(); i++) {
            String eqt = (String)o.get(i);
            <option value="<%=eqt %>"><%=eqt %></option>

I get this error,  can anyone help

[7/9/03 12:50:10:016 EDT] 868b89 WebGroup E SRVE0026E: [Servlet Error]-[No
getter method available for property key for bean under name yerSelectBox]:
javax.servlet.jsp.JspException: No getter method available for property key
for bean under name yerSelectBox
at org.apache.struts.taglib.html.OptionsTag.doEndTag(
at javax.servlet.http.HttpServlet.service(
"sjones" <> wrote in message
> Good Morning Everyone.
> I have a List object and i need my JSP page
> to build a drop down list box using the List as the source
> for the options.
> I can do it with a scriplet but i need to one of the struts tags
> <html:options>
> <html:optionsCollection>
> can anyone help me with use one of these tags.
> I am looking at the but it doesn't really help me.
> the List is also accessible from a classs name EqualityOperators
> List o = EqualityOperators.getOperators();

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message