How to use java application coding to make a web service(web application)

I have develop a full java application using netbeans and it run correctly.

Now I want to convert it to web application because I want my application viewed as web page (.html) in localhost. (web service)

Do I have to rewrite the coding and add some function or i can just import the source code into the web application project.

Is it same as embed applet in .html?

Please anyone... Help me..

[425 byte] By [suhyea] at [2007-11-26 21:47:32]
# 1
Do you mean uing the <applet> tags?
Chris1234554a at 2007-7-10 3:37:46 > top of Java-index,Java Essentials,Java Programming...
# 2
> Do you mean uing the <applet> tags?no..not <applet> tag.i mean that java application coding to web service (web app)..how?or is it simpler using embed applet than web app if i want to make it as web based as beginner like me?
suhyea at 2007-7-10 3:37:46 > top of Java-index,Java Essentials,Java Programming...
# 3

There is no way we can answer your question because we do not know what your application is.

Is it a Swing based GUI app? If so then with a minimal amount of coding you can convert it to an applet, and then write a servlet that would be hosted on the server to handle communication between the server and the applet.

maple_shafta at 2007-7-10 3:37:46 > top of Java-index,Java Essentials,Java Programming...
# 4

Do you know web application/service programming at all? If not, learn that first (lookup J2EE). Otherwise this question is like asking "how do I build a house using a hammer and nails?" You can definately be taught to do it, but not by someone simply attempting to answer that question.

They would have to write a book to answer that question, the same we would need to do here.

masijade.a at 2007-7-10 3:37:46 > top of Java-index,Java Essentials,Java Programming...
# 5
I think he wants rather a JSP/Servlet application
java_2006a at 2007-7-10 3:37:46 > top of Java-index,Java Essentials,Java Programming...
# 6
thanks for all replies..now i make it as applet, the easiest way to make it as web based.thanks again.
suhyea at 2007-7-10 3:37:46 > top of Java-index,Java Essentials,Java Programming...