aspose file tools*
The moose likes Servlets and the fly likes Applet to Servlet Communication Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "Applet to Servlet Communication" Watch "Applet to Servlet Communication" New topic
Author

Applet to Servlet Communication

Mohit Agarwal
Ranch Hand

Joined: Mar 30, 2004
Posts: 88
Hi to all ,

I had a Applet which needs to read some data from the database.
The data is read from the database via a Servlet .The requisite data
is there in the Value Objects wrapped inside an ArrayList .
The servlet makes a ObjectOutputStream object passing
response.getOutputStream() as the argument & writes the ArrayList obj
in the output stream .

In the applet , i make a URL Connection obj named servletconnection. which points to that servlet .
Upto this point everything goes fine & the connection is established .
Now i make a ObjectInputStream obj & passes the arg as servletconnection.getInputStream().
When i prints the available size it shows as 0.
Am i not pointing to the correct stream .

Pls. help me out .

Bye n Tanks in Advance ,


Reagrds,
Mohit.
Annie Smith
Ranch Hand

Joined: Mar 05, 2005
Posts: 172
There are some good examples here that might help!


Cheers!<br /><b>Annie</b>
Manuel Moons
Ranch Hand

Joined: Mar 05, 2002
Posts: 229
For applet-servlet communication the jakarta httpclient api is always interesting.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Applet to Servlet Communication
 
Similar Threads
Passing more than one object
Applet doesn't establish JDBC connection
Applet-servlet communication
simple questions
Servlet to applet communication