Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

how to write UseBean tag

Posted on 2007-03-20
3
Medium Priority
?
270 Views
Last Modified: 2013-12-29
Hi Guys

I have a InputDataBean which I call from my JSP file using the following code. Now I needed to use UseBean tag instead of the java code. I am a newbie on ?JStL tags. Would you guys know how can i do that

Thanks
-------------------------------------------------------------
SRSReportingDataBean reportingDb = new SRSReportingDataBean();
reportingDb.setSqlQuery("CATALOG");
reportingDb.setResourceBundle("com.srs.common.properties.SRSReportingMessages");//USER_RESOURCE_BUNDLE
com.ibm.commerce.beans.DataBeanManager.activate(reportingDb, request, response);
String []reportResult=reportingDb.getReportResultSet();

-------------------------------------------------------------

0
Comment
Question by:huzefaq
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 10

Expert Comment

by:Jaax
ID: 18761782
In your JSP use something like this
<!-- For Cart Bean-->
<jsp:useBean id="cart" scope="session" class="session.Carts" />
<jsp:setProperty name="cart" property="*" />

<!-- For Checking Bean-->
<jsp:useBean id="checking" scope="session" class="bank.Checking" > 
<jsp:setProperty name="checking" property="balance" value="0.0" />
</jsp:useBean>

0
 

Author Comment

by:huzefaq
ID: 18761963
Thanks,

Also how can I pass parameters, two of the parameters would be String and one HashTable

Thanks

0
 
LVL 19

Accepted Solution

by:
Kuldeepchaturvedi earned 2000 total points
ID: 18762061
you shd be able to do
<jsp:useBean id="cart" scope="session" class="session.Carts" />

<% cart.methodName(parm1,parm2);
%>
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Are you developing a Java application and want to create Excel Spreadsheets? You have come to the right place, this article will describe how you can create Excel Spreadsheets from a Java Application. For the purposes of this article, I will be u…
Introduction Java can be integrated with native programs using an interface called JNI(Java Native Interface). Native programs are programs which can directly run on the processor. JNI is simply a naming and calling convention so that the JVM (Java…
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.
This video teaches viewers about errors in exception handling.
Suggested Courses

722 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question