Create applet
hello. i'm new to intellij and i have a question. i have created an applet using built-in ui designer. from the ide it runs well, but i cant make it load from html. i just dont know what classes beside the one that i created myself i need to include in the directory with the class and in wich subdirs. or do i need to create a jar and set it in the archive option of the applet tag? if so how do i create the needed jar with ui classes.
or maybe intellij has it's own built-in applet creator like jbuilder?
i'll be glad if some1 could help me out. :)
Message was edited by:
modoom
请先登录再写评论。
Hello modoom,
It depends. Do you use FormLayout (JGoodies) or GridLayoutManager (IntelliJ)
in the applet you've created?
(These two are suggested along with others when you create a new UI form
in IDEA.)
Alexander.
i'm using GridLayoutManager (IntelliJ)
anyone? plz help...
ok. i got it working with a simple applet. needed to add archive to the applet tag.
but my prog still doesn't show in browser. here i what java console says:
java.lang.NoClassDefFoundError: Could not initialize class com.intellij.uiDesigner.core.SupportCode
at FreeMinimizer.$$$setupUI$$$(FreeMinimizer.java)
at FreeMinimizer.]]>(FreeMinimizer.java:14)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
at java.lang.reflect.Constructor.newInstance(Unknown Source)
at java.lang.Class.newInstance0(Unknown Source)
at java.lang.Class.newInstance(Unknown Source)
at sun.applet.AppletPanel.createApplet(Unknown Source)
at sun.plugin.AppletViewer.createApplet(Unknown Source)
at sun.applet.AppletPanel.runLoader(Unknown Source)
at sun.applet.AppletPanel.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Source)
Most probably you didn't add forms_rt.jar to your applet tag.
modoom wrote:
--
Martin Fuhrer
Fuhrer Engineering AG
http://www.fuhrer.com
Hello modoom,
You need to have corresponding classes available for your applet.
To see these classes set option Settings / GUI Designer / Automatically copy
form runtime classes = ON. And compile you GUI form. In the output (by default
this is (your project directory)/classes/production/(your module)) you will
see a set of classes in the package com.intellij.uiDesigner.core. That's
they are. You need to pack them into some archive (I use IDEA main menu /
Build / Build jars - it can pack all compiler's output into the jar) and
provide necessary "archive" attribute in HTML applet tag.
Alexander.
(And Martin is also right, these classes are included into forms_rt.jar.)
Alexander.