Hi there.
I have a
servlet that populates a bean, using Enumeration and a Vector, with information from a database. The servlet then starts a
JSP. I would like the JSP to then print out the information in the bean into the browser.
I've imported java.sql.* and java.util.* at the start of the jsp, and then:
<jsp:useBean id = "infobean" class="MikeBean"/>
<html><body>
<%
private Vector infobean = new Vector();
{
for (Enumeration e = infobean.elements();e.hasMoreElements()
{
out.println((
String) e.nextElement() + " ");
}
%>
</body></html>
I'm TOTALLY new to this stuff and all I did was copy the output method from the MikeBean
java file.
Thanks in advance for any help.
Mike