Title: RE: About Applet-serlvet communication

setUseCaches(false) does the trick

the following is a funciton within an applet. The function calls info_feed.jsp to retrieve
data in db.  (data is formatted as a string at info_feed.jsp)

Hope this helps

J.H

private void Get_Information_From_Sever(String tableName) throws MalformedURLException, IOException
    {

             URL  url = new URL( "http://myserver/jsp/info_feed.jsp?table=" + tableName);
                //?table=" + tableName);
                URLConnection con= url.openConnection();
                con.setUseCaches(false);  // The magic
                InputStream in = con.getInputStream();
                DataInputStream textStream;
                textStream = new DataInputStream(in);
                String strLine = textStream.readLine();
                //strLine looks like "*Chicago*New York*Seatle*Huston"         

                //load info in string to the comboBox  
             LoadtoComboBox(strLine, "*", choice_1);

        }
   
-----Original Message-----
From: meera nayak [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, January 12, 2000 3:37 AM
To: [EMAIL PROTECTED]
Subject: About Applet-serlvet communication


HI Room
            I have an applet passing values to a serlvet through
dataoutputstreams ,the servlet reads this using datainputstream.The
values are read correctly by the applet
and shown in the java console.But on the browser window it outputs
previous immmediate valuein the outputstream of the servlet.I dodn't
understand the problem coz the java console shows the current value.I
flush and close the outputstream also.Are the values in the outputstream
cached?
can anyone help

regards
Meera

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
FAQs on JSP can be found at:
 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html

Reply via email to