I want to pass a value from an applet to the HTML page (which contains the applet) .This should happen on click event of a button in the applet.
maateen ashraf
Ranch Hand
Joined: Jan 08, 2001
Posts: 122
posted
0
just run a servlet on server side from where the applet has been loaded to client machine now pass this value to servlet by response object.
Revati Pathak
Greenhorn
Joined: Feb 19, 2001
Posts: 26
posted
0
hi, i know i can easily do it using servlets but i don't want to use servlet. regards, -Revati
Originally posted by maateen ashraf: just run a servlet on server side from where the applet has been loaded to client machine now pass this value to servlet by response object.
Rahul Rathore
Ranch Hand
Joined: Sep 30, 2000
Posts: 324
posted
0
Sorry for my ignorance, but I could not understand the question. What do you mean by passing a value from an applet to the HTML page containing it?? Can you be more specific? What value you want to pass, to what object? Do you want the HTML page to change- how, what, when??
Ramneek Handa
Ranch Hand
Joined: Nov 10, 2000
Posts: 44
posted
0
Hi! Maateen sorry i did not get what you what to tell. how can we pass a value to a servlet through response object. i believe we can pass a value only through request only. and even then how can we pass it to the html which is running that applet which is calling the servlet. pls explain
maateen ashraf
Ranch Hand
Joined: Jan 08, 2001
Posts: 122
posted
0
u can use URL class to send html to browser.. try it
maateen ashraf
Ranch Hand
Joined: Jan 08, 2001
Posts: 122
posted
0
hi Ramneek Handa u will use request object to send values to servlet & use response object to pass it to browser
Rahul Rathore
Ranch Hand
Joined: Sep 30, 2000
Posts: 324
posted
0
Hi mateen If we send a response using response object, it will send a new HTML page [B] to the browser. But the Revati's original question is - how to pass values from the applet, to HTML page [B] containing the applet. I could not understand
Originally posted by maateen ashraf: hi Ramneek Handa u will use request object to send values to servlet & use response object to pass it to browser
anuj khanna
Greenhorn
Joined: Jan 11, 2001
Posts: 20
posted
0
hi, i'm not sure how to pass the value from the applet to the web-page but don't u think if u're able to pass a value to the HTML page u're actually making a dynamic page from an applet ,and i suppose a servlet is supposed to do this,generate a dynamic page
Sarath Mohan
Ranch Hand
Joined: Mar 17, 2001
Posts: 213
posted
0
Hi, Try this: AppletContext ac = getAppletContext(); ac.showDoucumet(new URL("your htmlpage with this applet"?partameters, "_SAME")); Check the second parameter in the URL constructor for correctness OK
Sarath Mohan
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to
run our stuff on 16 servers instead of 3.