Tell me, for example, I already have a ready-made program, is it possible (and how) to create an applet that implements the same thing as a program? Or do you have to create a "clean" applet and rewrite this program in it?
3 answers
I'm afraid it's easier to do quite the opposite. All program code to put in the applet. Add to it the main
method like this:
JFrame f = new JFrame ("using applet"); f.add( new CustomApplet() ); ... f.setVisible(true);
The main
method will only be used in program mode. i.e applet has a completely different entry-point
|
Weird question. It depends on what program you want to receive. Most likely, it will be possible to use some parts, some classes, etc. But something will have to be rewritten or added, of course.
- MVC, extend JFrame replace with extend Applet, remove unnecessary methods and if there is something not too complicated, in terms of GUI, then it should work - Gorets
|
Try to dig into the java web start. java web start
If you have the opportunity to translate your project into the netbeans environment, then there is an automation of creating a JWS application variant.
|