applet-jsp communicatio

hi all
i am very new in java so please spend your few movement for this topic.
i want to run a jsp page from within an applet and evantually want to send data to jsp.

please help me with approppiate code that you have used using HttpPost and HttpGet method both.
the data is an array of string object or may be a properties object,
[352 byte] By [tanya_87] at [2007-11-20 11:53:01]
# 1 Re: applet-jsp communicatio
i want to run a jsp page from within an appletThat's a little unusual - how are you proposing to do this?

Don't worry about people stealing your ideas. If your ideas are any good, you'll have to ram them down people's throats...
H. Aiken
dlorde at 2007-11-10 2:14:00 >
# 2 Re: applet-jsp communicatio
thanks Mr dArlode for ur quick reply..

sorry not to explaing my intention..

i have embedded a japplet class into a jsp pagea(say mypage.jsp).

and now i proposed to send few data from myjsp.jsp to another jsp(say target.jsp) when user clicks the button inside that japplet class.

both jsp's are in same web dorectory of my project. i m usin tomcat bundeled with NetBeans 5.5.1 and IE7.0

please help me out using both httpget and http post method along with ur
code u got succeed in.
its very urgent!!!
tanya_87 at 2007-11-10 2:15:00 >
# 3 Re: applet-jsp communicatio
Sorry, I don't know the answer to that, offhand. I'm sure someone else will be along shortly...

Computers are useless. They only give you answers...
Picasso
dlorde at 2007-11-10 2:16:01 >
# 4 Re: applet-jsp communicatio
i have been using the following code for that..but i haven't written any code inside the target jsp(to which i want to cummunicate) so for.
is it compulsory to write the code bothside(applet and jsp),in fact i will do it latter.

code:
------------------------

try{
URL appletURL = getCodeBase();
String strHost = appletURL.getHost();
String strPort = String.valueOf(appletURL.getPort());
String strProtocol = appletURL.getProtocol();
int portNumber = Integer.parseInt(strPort);
String strwp ="/UASProject/Registrationform.jsp";
URL jspURL = new URL(strProtocol,strHost,portNumber,strwp); URLConnection jspCon = jspURL.openConnection(); jspCon.setUseCaches(false);
jspCon.setDoOutput(true);
jspCon.setDoInput(true);
OutputStream outstream= jspCon.getOutputStream(); ObjectOutputStream oboutStream = new ObjectOutputStream(outstream);

String strLength = String.valueOf(oboutStream); jspCon.setRequestProperty("Content-Length",strLength); jspCon.setRequestProperty("Content-Type","application/x-www-form-urlencoded");
oboutStream.writeObject(std_details);
oboutStream.flush();
oboutStream.close();
URL tempURL = new URL(String.valueOf(jspURL)); getAppletContext().showDocument(tempURL,"_blank");
}catch(Exception e) {System.out.println(e+" "+e.getCause());}

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

after working with this i got the follwing exception
java.lang.IllegalStateException: Already connected
i looked around this but couldn't able to solve.

guide me to make a successful connection
tanya_87 at 2007-11-10 2:16:56 >