Autor Zpráva
Viktor 36
Profil
Ahojte,

Potrebujem pomoc. Mám takú aplikáciu v jave .jar názov ma "client.jar" a používa súbor .class s menom "EGUI.class" a chcel by som si to vložit na web ale mi píše stále nejaký error a neviem si na to urobiť vlastný applet kód. Vytvorí mi niekto applet kód ktorý bude fungovať??? :D Prosím

Toto sa nachádza v "EGUI.java" ak by ste potrebovali
import java.awt.BorderLayout;
import java.awt.Cursor;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import javax.swing.*;

public class EGUI
{
    public static void main(String args[])
    {
                    client.main(new String[] {
                "127.0.0.1", "127.0.0.1", "127.0.0.1"
            });
        }
    }

Moderátor Chamurappi: Titulek „Java Applet“ nevystihuje podstatu dotazu. Příště zkus prosím vymyslet lepší.
Chamurappi
Profil
Reaguji na Viktora 36:
Jak souvisí dotaz s JavaScriptem? Přesouvám do Jak něco udělat.

ale mi píše stále nejaký error
Nějaký? To je snadné — oprav tu chybu nějak.

Myslím, že uvedený kód je příliš triviální na to, aby z něj někdo pochopil, o co vlastně jde a v čem je problém.
Viktor 36
Profil
Chamurappi:
presne ukazuje tam kde ten .jar mam vlozeny "Error. Click Here for details."
A ked kliknem tak ukazuje toto : Sorry za take Dlhe :D
Java Plug-in 1.6.0_17
Using JRE version 1.6.0_17-b04 Java HotSpot(TM) Client VM
User home directory = C:\Users\Viktor 36
----------------------------------------------------
c:   clear console window
f:   finalize objects on finalization queue
g:   garbage collect
h:   display this help message
l:   dump classloader list
m:   print memory usage
o:   trigger logging
q:   hide console
r:   reload policy configuration
s:   dump system and deployment properties
t:   dump thread list
v:   dump thread stack
x:   clear classloader cache
0-5: set trace level to <n>
----------------------------------------------------


java.lang.reflect.InvocationTargetException
	at com.sun.deploy.util.DeployAWTUtil.invokeAndWait(Unknown Source)
	at sun.plugin2.applet.Plugin2Manager.runOnEDT(Unknown Source)
	at sun.plugin2.applet.Plugin2Manager.createApplet(Unknown Source)
	at sun.plugin2.applet.Plugin2Manager$AppletExecutionRunnable.run(Unknown Source)
	at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.ClassCastException: EGUI cannot be cast to java.applet.Applet
	at sun.plugin2.applet.Plugin2Manager$12.run(Unknown Source)
	at java.awt.event.InvocationEvent.dispatch(Unknown Source)
	at java.awt.EventQueue.dispatchEvent(Unknown Source)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
	at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
	at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
	at java.awt.EventDispatchThread.run(Unknown Source)
Exception: java.lang.reflect.InvocationTargetException
java.lang.NullPointerException
	at sun.plugin2.applet.Plugin2Manager.findAppletJDKLevel(Unknown Source)
	at sun.plugin2.applet.Plugin2Manager.createApplet(Unknown Source)
	at sun.plugin2.applet.Plugin2Manager$AppletExecutionRunnable.run(Unknown Source)
	at java.lang.Thread.run(Unknown Source)
Exception: java.lang.NullPointerException
java.lang.reflect.InvocationTargetException
	at com.sun.deploy.util.DeployAWTUtil.invokeAndWait(Unknown Source)
	at sun.plugin2.applet.Plugin2Manager.runOnEDT(Unknown Source)
	at sun.plugin2.applet.Plugin2Manager.createApplet(Unknown Source)
	at sun.plugin2.applet.Plugin2Manager$AppletExecutionRunnable.run(Unknown Source)
	at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.ClassCastException: EGUI cannot be cast to java.applet.Applet
	at sun.plugin2.applet.Plugin2Manager$12.run(Unknown Source)
	at java.awt.event.InvocationEvent.dispatch(Unknown Source)
	at java.awt.EventQueue.dispatchEvent(Unknown Source)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
	at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
	at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
	at java.awt.EventDispatchThread.run(Unknown Source)
Exception: java.lang.reflect.InvocationTargetException
java.lang.NullPointerException
	at sun.plugin2.applet.Plugin2Manager.findAppletJDKLevel(Unknown Source)
	at sun.plugin2.applet.Plugin2Manager.createApplet(Unknown Source)
	at sun.plugin2.applet.Plugin2Manager$AppletExecutionRunnable.run(Unknown Source)
	at java.lang.Thread.run(Unknown Source)
Exception: java.lang.NullPointerException

Vaše odpověď


Prosím používejte diakritiku a interpunkci.

Ochrana proti spamu. Napište prosím číslo dvě-sta čtyřicet-sedm:

0