This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
I am generating a generic/dynamic form for multiple database tables. Is there a way of selecting which bean or java code to use depending on the table? Ie: <jsp:useBean id='object' scope='page' class='<%= classname%>' <jsp:setProperty name="object" property="*"/> This code doesn't work. Is there another way of doing this either in the JSP or a bean. Please help - its driving me mad!!! Langers
"langers" your name doesn't seem to agree with the javaranch guidelines. please take a moment and re-register after reviewing the guidelines at http://www.javaranch.com/name.jsp thanks for your cooperation. - satya
Try writing a custom tag to do this. You can then put whatever bean you want back into the session/request. You should be able to find an example of this in any elementary JSP book. Also see the JavaOne presentations on my website.
If you want more info please post again.
<a href="http://www.samjdalton.com" target="_blank" rel="nofollow">Sam Dalton</a>,<br />Co-author of [http://www.amazon.com/exec/obidos/tg/detail/-/1590592255/qid=1068633302//ref=sr_8_xs_ap_i0_xgl14/104-4904002-9274339?v=glance&s=books&n=507846]Professional JSP 2.0[/URL] (October 2003)<br />Co-author of <a href="http://www.amazon.com/exec/obidos/ASIN/1861007701/ref=ase_electricporkchop" target="_blank" rel="nofollow">Professional SCWCD Certification</a><br />Co-author of <a href="http://www.amazon.com/exec/obidos/ASIN/186100561X/ref=ase_electricporkchop" target="_blank" rel="nofollow">Professional Java Servlets 2.3</a>