Latest Tutorials| Questions and Answers|Ask Questions?|Site Map



Home Answers Viewqa JSP-Servlet Servlet - JSP

Have Programming Question? Ask it here!
 
 
 


Kiran
Servlet - JSP
0 Answer(s)      4 years and 3 months ago
Posted in : JSP-Servlet


i used arraylist in servlet as shown

ArrayList <Integer> total = new ArrayList <Integer>();
...
total.add(k[i]);

session.setAttribute("efg",total);

when I code this like in my jsp
<%ArrayList<Integer> data= new ArrayList<Integer>(); %>

<%Iterator itr;%>
<% //List data;
data= (ArrayList)session.getAttribute("efg");
for (itr=data.iterator(); itr.hasNext(); )
{
%>

<%=itr.next()%>

Its not printing the values. do i need to do any typecast or anything else. I'm sure mu k[i] have some value. please let me know. Its showing some exception at line iterator itr; and data= (ArrayList)session.getAttribute("efg"); like iterator is a raw type..

Advertisement
View Answers

Related Tutorials/Questions & Answers:
Servlet
Servlet  What is Servlet
Servlet
Servlet  how to navigate one servlet page to another servlet page
Advertisements
servlet
servlet  is there any way to include pdf's in servlet
servlet
servlet  How many times the servlet is accessed
servlet
servlet  what are the methods and interfaces in the servlet api ?   Servlet Tutorials
servlet
servlet  how to interact with a servlet from a swing program
servlet
servlet  what are the all necessary configuration to run a servlet
servlet
servlet  I designed 1 html form & a servlet but when I click on form I don't get output of servlet Please help
servlet
servlet  I designed 1 html form & a servlet but when I click on form I don't get output of servlet Please help
Servlet
override Service method in the servlet when you extend GenericServlet to create servlet as it is mandatory to override it. But, when you extend HttpServlet to create a servlet then you can't override service method as there is a need to override
servlet
of the Servlet API. It contains the classes necessary for a standard, protocol-independent servlet. Every servlet must implement the Servlet interface in one
servlet
servlet  can i stoar record in variable which selected from table in servlet
servlet
servlet  dear sir servlet and html not run on eclips plz help me
servlet
servlet  how to create a login form using servlet using submit,edit delete button
servlet
servlet  i want a program for counting the no of times the servlet has been invoked
Servlet
Servlet  What must be implemented by all Servlets?    The Servlet Interface must be implemented by all servlets
Servlet
Servlet  I want to know the steps to write a simple servlet program... .   Hello Friend, Follow these steps: Put servlet-api.jar inside the lib folder of apache tomcat. 1)create a servlet. import java.io.*; import
servlet
servlet  how to read a file from different folder using filereader in servlet   Hello Friend, Please visit the following link: http://www.roseindia.net/servlets/servlet-read-file.shtml Here you will get an useful
servlet
servlet  i want to use servlet application on my web page then what should i do. I have already webspace.   Hi Friend, Please visit the following link: Servlet Tutorials Thanks
Servlet
Servlet   Why is Servlet so popular?   Because servlets are platform-independent Java classes that are compiled to platform-neutral byte code that can be loaded dynamically into and run by a Java technology-enabled Web
Servlet
Servlet  Hi, Can any one please expalin me below topics SERVLET ENGINE 2.WHY SUPER.INIT(); Thanks alot in advance!! Regards: Akash
servlet
servlet  I want a fully readymade project on online voting system with code in java servlet and database backend as msaccess.can u plz send me as soon as possible
servlet
servlet  plz can anyone give me the link of javax library jar file. i badly need that. thanks in advance   Please visit the following link: Download Servlet API
servlet
servlet   Dear Deepak, is it compulsary to write the sevice() becoz i ve seen some example which does not ve sevice()..is it tue? plz replay me with thanks praveen
Servlet
the same error <web-app> <servlet> <servlet-name>InsertServlet</servlet-name> <servlet-class>InsertServlet</servlet-class> </servlet> <servlet-mapping> <servlet-name>
servlet
servlet file which prints out the user's inputs. I need to use the post method to pass the data from html to the java servlet and also use both doGet and doPost methods in the servlet. I think, but unfortunately I have a terrible teacher
servlet
servlet  hi sir,this is ashok.i installed tomcat 6.0 and jdk-150.i checked the server it's working but when execute servlet program for the .class file it shows the errors javax.servlet is not exist.what can i do,please tell me
servlet
servlet  How do we define an application level scope for servlet?   Application scope uses a single namespace, which means all your pages should be careful not to duplicate the names of application scope objects
servlet
to servlet. So, if anyone can help me so I can see how to connect the two I would
servlet
servlet   try { con=DaoPack.createConnection(); } catch(Exception e) { e.printStackTrace(); } if(request.getParameter("addproduct")!=null) { ProductBean bean=new ProductBean
servlet
servlet   try { con=DaoPack.createConnection(); } catch(Exception e) { e.printStackTrace(); } if(request.getParameter("addproduct")!=null) { ProductBean bean=new ProductBean
servlet
com.ilp.tsi.pm.services.StockService; /** * Servlet implementation class AddServlet1 */ //Servlet for Adding the stock public class AddStockServlet extends...; import com.ilp.tsi.utils.*; /** * Servlet implementation class Changepwd
servlet
com.ilp.tsi.um.bean.BankBean; import com.ilp.tsi.um.service.BankService; /** * Servlet
servlet - Servlet Interview Questions
Servlet Priority  How to set priority for servlet?  in web.xml file we can set priority of servlet. 1 2
servlet - Servlet Interview Questions
servlet  what is the full form of servlet
servlet - Servlet Interview Questions
servlet  what is the full form of servlet
Servlet chaining
Servlet chaining  What is Servlet chaining
servlet container
servlet container  What is servlet container
Servlet Context
Servlet Context  Defined Servlet Context
servlet initialization
servlet initialization  define servlet initialization
servlet Service
servlet Service  Defined servlet Service
servlet - Servlet Interview Questions
naming convention for servlet in java  Need to know the naming convention for servlet in java  Hi,Yes servlet.jar and servlet-api.jar is the same file. In case of tomcat servlet.jar is just renamed to servlet
Servlet - Servlet Interview Questions
Servlet  How To WAR servlet programs and how to deploy in weblogic
servlet - Servlet Interview Questions
, the servlet container will load the servlet class and create servlet object when it receives the first request call for that particular servlet. But, by using the load-on-startup in web.xml for a particular servlet will make the servlet
servlet mapping
servlet mapping  Defined servlet mapping in web.xml ?   <servlet> <servlet-name>Hello</servlet-name> <servlet-class>HelloWorld</servlet-class> </servlet> <servlet-mapping>
servlet questions
servlet questions  pls send servlet interview questions to anvesh2406@gmail.com
servlet-error
servlet-error  where we declare a servlet errors in web application
servlet - Servlet Interview Questions
, Service method in called by the servlet container to process a request from the browser. When user calls a servlet, it's service method is executed by servlet container to process the user request. So, service method is called
Java servlet
Java servlet  What is servlet
Java(Servlet) - Servlet Interview Questions
Java Servlet examples  Java and Servlet programming examples
Advertisements
 

 

 

DMCA.com