Java Swing Applets in Mac Os

hi there,
I am a student at the University of Portsmouth in the UK in my third and last year. I am doing my dissertation as a game using applets for a client at the university of which there consits four prototypes. One of the main specification points is that it should work on an apple mac, therefore I am using Swing applets. however with my first prototype it works fine on windows in windows Explorer, firefox and Netscape but i cant get it to work on Mac os 9 or X even with the latest version of java installed on the machine. Can anyone tell me why this is so, I would be very gratefull.
As I cant post the whole applet here as a file download I will just put some code snippets of the main program classes.
Applet ------------------------------
* Class JugglingBalls - A sub class of JApplet that combines the GameInterface and GamePanel into a single application
* @author (Liam Morren)
* @version (v1.0)
import java.awt.*;
import javax.swing.*;
public class JugglingBalls extends JApplet
    // instance variables -----------------------------------------------------------------------------------------------------------------------------------
    private GamePanel gamePanel; // The game panel including game and render loop
    private GameInterface gameInterface; // The swing interface to modify the game scene components
    // JApplet methods -------------------------------------------------------------------------------------------------------------------------------------
     * Called by the browser or applet viewer to inform this JApplet that it
     * has been loaded into the system. It is always called before the first
     * time that the start method is called.
    public void init()
        gamePanel = new GamePanel();
        gameInterface = new GameInterface(gamePanel.getGameScene());
        Container content = getContentPane(); // The container for components in the applet
        setLayout(new BoxLayout(content, BoxLayout.X_AXIS));
        content.add(gamePanel);
        content.add(gameInterface);
     * Returns information about this applet.
     * An applet should override this method to return a String containing
     * information about the author, version, and copyright of the JApplet.
     * @return a String representation of information about this JApplet
    public String getAppletInfo()
        // provide information about the applet
        return "Title: JugglingBalls  \nAuthor: Liam Morren  \nA simple application showing balls juggling in the air.";
Interface -------------------------------------
* Class GameInterface - Lets you manipulate the game components using swing components
* @author (Liam Morren)
* @version (v1.0)
import java.awt.*;
import javax.swing.*;
import java.awt.event.*;
import javax.swing.event.*;
public class GameInterface extends JPanel
    // instance variables -------------------------------------------------------------------------------------------------------------------------------------
    private GameScene gameScene; // Reference to the game scene
    private JTabbedPane gameTabs; // Tabs for Game, Balls and Background
    // Scene panel
    JButton pause, start, reset; // Buttons
    // Balls panel
    JRadioButton redBall, greenBall, blueBall, archBall, figureOfEightBall; // Radio buttons
    JCheckBox canSplit; // Check box
    JComboBox setAllPaths, setAllTypes, newBall, selectBall; // Drop down boxes
    JButton deleteBall; // Button
    Ball currentBall; // Current ball being changed
    // Background panel
    JRadioButton black, white, red, green, blue, hide, show, stop, move, arch, figureOfEight; // Radio buttons
    // Constructors -------------------------------------------------------------------------------------------------------------------------------------------
     * Constructor for objects of class GameInterface
    public GameInterface(GameScene gameSceneIn)
        gameScene = gameSceneIn; // Reference to the game scene
        gameTabs = new JTabbedPane(); // JTabbedPane to hold different toolbars
        gameTabs.setPreferredSize(new Dimension(200, 494)); // Set the preffered size for the tabbed pane
        currentBall = gameScene.getBall(0); // First ball
        // Add the panels to the tabbed pane
        gameTabs.addTab("Scene", makeScenePanel());
        gameTabs.addTab("Balls", makeBallsPanel());
        gameTabs.addTab("Background", makeBackgroundPanel());
        add(gameTabs); // Add the tab to the game interface panel
        setPreferredSize(new Dimension(200, 200));
    // Other methods ------------------------------------------------------------------------------------------------------------------------------------------
     * makeScenePanel
     * @return JPanel - The scene panel with buttons added
    private JPanel makeScenePanel()
        // Make scene panel
        JPanel scenePanel = new JPanel();
        scenePanel.setLayout(new BoxLayout(scenePanel, BoxLayout.Y_AXIS)); // Change layout
        pause = new JButton("Pause"); // Make buttons
        start = new JButton("Start");
        reset = new JButton("Reset");
        // Add button actions
        pause.addActionListener(new ActionListener() // Add button listener to pause button
            public void actionPerformed(ActionEvent ev) // Overide actionPerformed() method
                gameScene.setPaused(true); // Pause game
        start.addActionListener(new ActionListener() // Add button listener to start button
            public void actionPerformed(ActionEvent ev) // Overide actionPerformed() method
                gameScene.setPaused(false); // Unpause game
        reset.addActionListener(new ActionListener() // Add button listener to reset button
            public void actionPerformed(ActionEvent ev) // Overide actionPerformed() method
                gameScene.reset(); // Reset game
                updateSelectBallComboBox();
                changeSelectedBall(0);
        scenePanel.add(pause); // Add buttons to scene panel
        scenePanel.add(start);
        scenePanel.add(reset);
        return scenePanel;
     * makeBackgroundPanel
     * @return JPanel - The background panel with buttons added
    private JPanel makeBackgroundPanel()
        // Make scene panel
        JPanel backgroundPanel = new JPanel();
        backgroundPanel.setLayout(new GridLayout(5, 1, 2, 2)); // Change layout
        // Make buttons
        // background colour buttons
        JPanel backgroundcolour = new JPanel(); // Change backgroundcolour panel
        backgroundcolour.setBorder(BorderFactory.createLineBorder(Color.black));
        black = new JRadioButton("Black"); // Radio buttons to change colour
        white = new JRadioButton("white");
        black.setSelected(true); // Set black as already selected
        ButtonGroup backColourGroup = new ButtonGroup(); // Group buttons so only one can be pressed at a time
        backColourGroup.add(black); // Add buttons to group
        backColourGroup.add(white);
        backgroundcolour.setLayout(new GridLayout(2, 2, 0, 0)); // Change layout
        backgroundcolour.add(new JLabel("Background colour")); // Add label
        backgroundcolour.add(black); // Add buttons to colours panel
        backgroundcolour.add(white);
        // Add radio button actions
        black.addActionListener(new ActionListener() // Add button listener to black button
            public void actionPerformed(ActionEvent ev) // Overide actionPerformed() method
                gameScene.setBackgroundColour(false); // Background colour = black
        white.addActionListener(new ActionListener() // Add button listener to white button
            public void actionPerformed(ActionEvent ev) // Overide actionPerformed() method
                gameScene.setBackgroundColour(true); // Background colour = white
        // colour buttons
        JPanel colours = new JPanel(); // Change colours panel
        colours.setBorder(BorderFactory.createLineBorder(Color.black));
        red = new JRadioButton("Red"); // Radio buttons to change colour
        green = new JRadioButton("Green");
        green.setSelected(true); // Set green as already selected
        blue = new JRadioButton("Blue");
        ButtonGroup colourGroup = new ButtonGroup(); // Group buttons so only one can be pressed at a time
        colourGroup.add(red); // Add buttons to group
        colourGroup.add(green);
        colourGroup.add(blue);
        colours.setLayout(new GridLayout(2, 2, 0, 0)); // Change layout
        colours.add(new JLabel("Change colours")); // Add label
        colours.add(red); // Add buttons to colours panel
        colours.add(green);
        colours.add(blue);
        // Add radio button actions
        red.addActionListener(new ActionListener() // Add button listener to red button
            public void actionPerformed(ActionEvent ev) // Overide actionPerformed() method
                if (gameScene.getBackgroundEffect().getColour() != 0)
                    gameScene.getBackgroundEffect().setColour(0); // Background effect colour = red
        green.addActionListener(new ActionListener() // Add button listener to green button
            public void actionPerformed(ActionEvent ev) // Overide actionPerformed() method
                if (gameScene.getBackgroundEffect().getColour() != 1)
                    gameScene.getBackgroundEffect().setColour(1); // Background effect colour = green
        blue.addActionListener(new ActionListener() // Add button listener to blue button
            public void actionPerformed(ActionEvent ev) // Overide actionPerformed() method
                if (gameScene.getBackgroundEffect().getColour() != 2)
                    gameScene.getBackgroundEffect().setColour(2); // Background effect colour = blue
        // hide buttons
        JPanel hideShow = new JPanel(); // Change hideShow panel
        hideShow.setBorder(BorderFactory.createLineBorder(Color.black));
        hide = new JRadioButton("Hide"); // Radio buttons to hide show
        show = new JRadioButton("Show");
        show.setSelected(true); // Set show as already selected
        ButtonGroup hideShowGroup = new ButtonGroup(); // Group buttons so only one can be pressed at a time
        hideShowGroup.add(hide); // Add buttons to group
        hideShowGroup.add(show);
        hideShow.setLayout(new GridLayout(2, 2, 0, 0)); // Change layout
        hideShow.add(new JLabel("Hide / Show")); // Add label
        hideShow.add(hide); // Add buttons to hideShow panel
        hideShow.add(show);
        // Add radio button actions
        hide.addActionListener(new ActionListener() // Add button listener to hide button
            public void actionPerformed(ActionEvent ev) // Overide actionPerformed() method
                    gameScene.getBackgroundEffect().hide(); // Hide
        show.addActionListener(new ActionListener() // Add button listener to show button
            public void actionPerformed(ActionEvent ev) // Overide actionPerformed() method
                    gameScene.getBackgroundEffect().unHide(); // Unhide
        // stopMove buttons
        JPanel stopMove = new JPanel(); // Change StopMove panel
        stopMove.setBorder(BorderFactory.createLineBorder(Color.black));
        stop = new JRadioButton("Stop"); // Radio buttons to stop move
        move = new JRadioButton("Move");
        stop.setSelected(true); // Set stop as already selected
        ButtonGroup stopMoveGroup = new ButtonGroup(); // Group buttons so only one can be pressed at a time
        stopMoveGroup.add(stop); // Add buttons to group
        stopMoveGroup.add(move);
        stopMove.setLayout(new GridLayout(2, 2, 0, 0)); // Change layout
        stopMove.add(new JLabel("Stop / Move")); // Add label
        stopMove.add(stop); // Add buttons to stopMove panel
        stopMove.add(move);
        // Add radio button actions
        stop.addActionListener(new ActionListener() // Add button listener to stop button
            public void actionPerformed(ActionEvent ev) // Overide actionPerformed() method
                    gameScene.getBackgroundEffect().setMove(false); // stop
        move.addActionListener(new ActionListener() // Add button listener to move button
            public void actionPerformed(ActionEvent ev) // Overide actionPerformed() method
                    gameScene.getBackgroundEffect().setMove(true); // move
        // changePath buttons
        JPanel changePath = new JPanel(); // Change changePath panel
        changePath.setBorder(BorderFactory.createLineBorder(Color.black));
        arch = new JRadioButton("Arch"); // Radio buttons to change path
        figureOfEight = new JRadioButton("Figure of eight");
        arch.setSelected(true); // Set stop as already selected
        ButtonGroup changePathGroup = new ButtonGroup(); // Group buttons so only one can be pressed at a time
        changePathGroup.add(arch); // Add buttons to group
        changePathGroup.add(figureOfEight);
        changePath.setLayout(new GridLayout(2, 2, 0, 0)); // Change layout
        changePath.add(new JLabel("Change Path")); // Add label
        changePath.add(arch); // Add buttons to changePath panel
        changePath.add(figureOfEight);
        // Add radio button actions
        arch.addActionListener(new ActionListener() // Add button listener to arch button
            public void actionPerformed(ActionEvent ev) // Overide actionPerformed() method
                    gameScene.getBackgroundEffect().setPath(new Arch()); // Arch
        figureOfEight.addActionListener(new ActionListener() // Add button listener to figureOfEight button
            public void actionPerformed(ActionEvent ev) // Overide actionPerformed() method
                    gameScene.getBackgroundEffect().setPath(new FigureOfEight()); // Figure of eight
        // Add components to background panel
        backgroundPanel.add(backgroundcolour);
        backgroundPanel.add(colours);
        backgroundPanel.add(hideShow);
        backgroundPanel.add(stopMove);
        backgroundPanel.add(changePath);
        return backgroundPanel;
     * makeBallsPanel
     * @return JPanel - The ball panel with buttons added
    private JPanel makeBallsPanel()
        // Make balls panel
        JPanel ballsPanel = new JPanel();
        ballsPanel.setLayout(new BoxLayout(ballsPanel, BoxLayout.Y_AXIS)); // Change layout
        // Make buttons
        // set all drop down boxes
        JPanel setAll = new JPanel(); // Set all panel
        setAll.setBorder(BorderFactory.createLineBorder(Color.black));
        String[] setAllPathsChoices = {"Arch", "Figure of eight"}; // Selections for set all paths
        setAllPaths = new JComboBox(setAllPathsChoices); // Add selections to combo box
        String[] setAllTypesChoices = {"Primary ball", "Pastel ball", "3D ball", "Image ball"}; // Selections for set all types
        setAllTypes = new JComboBox(setAllTypesChoices); // Add selections to combo box
        setAll.add(new JLabel("Set all paths")); // Add combo boxes to set all panel
        setAll.add(setAllPaths);
        setAll.add(new JLabel("Set all types"));
        setAll.add(setAllTypes);
        // Add combo box actions
        setAllPaths.addActionListener(new ActionListener() // Add selection listener to set all paths combo box
            public void actionPerformed(ActionEvent ev) // Overide actionPerformed() method
                if (setAllPaths.getSelectedItem() == "Arch")
                    gameScene.setAllPathsArch();
                else
                    gameScene.setAllPathsFigureOfEight();
        setAllTypes.addActionListener(new ActionListener() // Add selection listener to set all types combo box
            public void actionPerformed(ActionEvent ev) // Overide actionPerformed() method
                if (setAllTypes.getSelectedItem() == "Primary ball")
                    gameScene.setAllTypesPrimaryBall();
                else if (setAllTypes.getSelectedItem() == "Pastel ball")
                    gameScene.setAllTypesPastelBall();
                else if (setAllTypes.getSelectedItem() == "Image ball")
                    gameScene.setAllTypesImageBall();
                else
                    gameScene.setAllTypesBall3D();
        // new ball drop down box
        JPanel newBallPanel = new JPanel(); // new ball panel
        newBallPanel.setBorder(BorderFactory.createLineBorder(Color.black));
        String[] newType = {"Primary ball", "Pastel ball", "3D ball", "Image ball"}; // Selections for new ball
        newBall = new JComboBox(newType); // Add selections to combo box
        newBallPanel.add(new JLabel("New ball")); // Add combo boxes to new ball panel
        newBallPanel.add(newBall);
        // Add combo box actions
        newBall.addActionListener(new ActionListener() // Add selection listener to newBall combo box
            public void actionPerformed(ActionEvent ev) // Overide actionPerformed() method
                String ballType = (String) newBall.getSelectedItem();
                if (ballType == "Primary ball")
                    gameScene.addBall(new PrimaryBall(gameScene));
                else if (ballType == "Pastel ball")
                    gameScene.addBall(new PastelBall(gameScene));
                else if (ballType == "Image ball")
                    gameScene.addBall(new ImageBall(gameScene));
                else
                    gameScene.addBall(new Ball3D(gameScene));
                updateSelectBallComboBox();
                changeSelectedBall(gameScene.getBalls().size() - 1); // Update interface to show new ball
        // selected ball panel
        JPanel selectedBallPanel = new JPanel(); // selected ball panel
        selectedBallPanel.setBorder(BorderFactory.createLineBorder(Color.black));
        // Select ball
        selectBall = new JComboBox(gameScene.getBallList()); // Add ball list to the select drop down box
        deleteBall = new JButton("DeleteBall"); // Delete button
        // Ball colour
        redBall = new JRadioButton("Red"); // Red choice
        redBall.setSelected(true); // Start as selected
        greenBall = new JRadioButton("Green"); // Green choice
        blueBall = new JRadioButton("Blue"); // Blue choice
        ButtonGroup ballColour = new ButtonGroup(); // So only one colour can be selected at a tim
        ballColour.add(redBall);
        ballColour.add(greenBall);
        ballColour.add(blueBall);
        // Path
        archBall = new JRadioButton("Arch"); // Arch path choice
        archBall.setSelected(true); // Start as selected
        figureOfEightBall = new JRadioButton("Figure of eight"); // Figure of eight path choice
        ButtonGroup ballPath = new ButtonGroup(); // So only one path can be selected at a tim
        ballPath.add(archBall);
        ballPath.add(figureOfEightBall);       
        // Can split
        canSplit = new JCheckBox("Can split", false); // Initialy not selected
        selectedBallPanel.add(new JLabel("Select ball")); // Add components to selected ball panel
        selectedBallPanel.add(selectBall);
        selectedBallPanel.add(deleteBall);
        selectedBallPanel.add(new JLabel("Ball colour"));
        selectedBallPanel.add(redBall);
        selectedBallPanel.add(greenBall);
        selectedBallPanel.add(blueBall);
        selectedBallPanel.add(new JLabel("Path"));
        selectedBallPanel.add(archBall);
        selectedBallPanel.add(figureOfEightBall);
        selectedBallPanel.add(canSplit);
        // Add select ball drop down box action
        selectBall.addActionListener(new ActionListener() // Add selection listener to selectBall combo box
            public void actionPerformed(ActionEvent ev) // Overide actionPerformed() method
                changeSelectedBall(selectBall.getSelectedIndex()); // Change the selected ball using the index from the select ball drop down box
        // Add delete button action
        deleteBall.addActionListener(new ActionListener() // Add selection listener to deleteBall button
            public void actionPerformed(ActionEvent ev) // Overide actionPerformed() method
                int tempIndex = selectBall.getSelectedIndex(); // Temp index
                if (gameScene.getBalls().size() > 1) // If there is more than 1 ball left
                    gameScene.removeBall(tempIndex); // Remove ball
                    updateSelectBallComboBox(); // Update with new ball list
                    changeSelectedBall(tempIndex - 1); // Update interface with new current selected ball
        // Add radio button colour actions
        redBall.addActionListener(new ActionListener() // Add button listener to redBall button
            public void actionPerformed(ActionEvent ev) // Overide actionPerformed() method
                if (currentBall.getColour() != 0)
                    currentBall.setColour(0); // currentBall colour = red
        greenBall.addActionListener(new ActionListener() // Add button listener to greenBall button
            public void actionPerformed(ActionEvent ev) // Overide actionPerformed() method
                if (currentBall.getColour() != 1)
                    currentBall.setColour(1); // currentBall colour = green
        blueBall.addActionListener(new ActionListener() // Add button listener to blueBall button
            public void actionPerformed(ActionEvent ev) // Background colour = blue
                if (currentBall.getColour() != 2)
                    currentBall.setColour(2); // currentBall colour = blue
        // Add path radio button actions
        archBall.addActionListener(new ActionListener() // Add button listener to arch button
            public void actionPerformed(ActionEvent ev) // Overide actionPerformed() method
                    currentBall.setPath(new Arch()); // Arch
        figureOfEightBall.addActionListener(new ActionListener() // Add button listener to figureOfEight button
            public void actionPerformed(ActionEvent ev) // Overide actionPerformed() method
                    currentBall.setPath(new FigureOfEight()); // Figure of eight
        // Add can split check button actions
        canSplit.addActionListener(new ActionListener() // Add button listener to can split
            public void actionPerformed(ActionEvent ev) // Overide actionPerformed() method
                    currentBall.setCanGiveBirth(canSplit.isSelected()); // Ball can split if can split check button is selected
        // Add components to ball panel
        ballsPanel.add(setAll);
        ballsPanel.add(newBallPanel);
        ballsPanel.add(selectedBallPanel);
        return ballsPanel;
     * changeSelectedBall
     * @param  ballIndexIn - The numbered index of the ball in the game scene list of balls. If less than 0 then equals 0. If more than ball list size then equals last ball
    public void changeSelectedBall(int ballIndexIn)
        if (ballIndexIn < 0) // Make sure index is within bounds
            ballIndexIn = 0;
        else if (ballIndexIn >= gameScene.getBalls().size())
            ballIndexIn = gameScene.getBalls().size() - 1; // Else put within bounds at either end
        currentBall.highlight(false); // Unhighlight current ball
        currentBall = gameScene.getBall(ballIndexIn); // Get new current ball
        currentBall.highlight(true); // Highlight new current ball
        // Update controls to new ball
        selectBall.setSelectedIndex(ballIndexIn);
        switch (currentBall.getColour()) // Update colour controls
            case 0: redBall.setSelected(true); break;
            case 1: greenBall.setSelected(true); break;
            default: blueBall.setSelected(true); break;
        if (currentBall.getPath() instanceof Arch) // If path is arch
            archBall.setSelected(true); // Update controls as arch
        else
            figureOfEightBall.setSelected(true); // Else figure of eight
        canSplit.setSelected(currentBall.canGiveBirth()); // Set if the ball can split or not
     * updateSelectBallComboBox
     * This method updates the combo box selection model with a new one made from the updated balls arraylist from the game scene
    public void updateSelectBallComboBox()
        DefaultComboBoxModel model = new DefaultComboBoxModel(gameScene.getBallList());
        selectBall.setModel(model);
}Kind regards
Liam morren

http://docs.info.apple.com/article.html?artnum=301073
This link states Mac OS X 10.4 now supports Java 5.0. It does mention nothing about Mac OS 9 or previous version of OS X. The problem you may be facing is that your Mac is running only 1.4.2 or less. The class files compiled for Java 5.0 can't run in non 5.0 versions of the Java Virtual Machine. Java 5.0 was a major release for the Java language and thus the change in numbering (though it took a little bit for this to change).
Anyway you should confirm what version of Java you have installed on your Mac.
At a command prompt:
java -version
The above URL states that the previous 1.4.2 Java version is not uninstalled, and this could still be the preferred version to use for Java applications even after installing Java 5.0.
The URL above states there is a utility to set your apps to use Java 5.0 as the perferred Java version. Who knows maybe this is all you need to do. I hope this is the case, then it probably is an easy fix, otherwise you may need to rewrite your app in Java 1.4.2 to get it to run on your version of Mac.

Similar Messages

  • How use system.out.println with a Java Swing Applet?

    Hi guys,
    I was just wondering what can I use to view output on the Java console with a Java Swing Applet?
    At the moment I'm using a JTextArea within the Applet for debugging but I want output to appear in the browser java console but system.out.println doesn't work.
    I'm viewing the Swing Applet on Netscape 4.7 browser.
    Any ideas?

    System.out.println()s work fine! I'm guessing that your problem is that you are looking at the wrong console window!
    You're using the Java Plug-in, right? On Windows, go to your Control Panel and double click "Java Plug-in". You should find a checkbox option to "Show Java Console" - make sure this is checked. Next time you fire up you JApplet, you should see a Java Console window popup.
    Hope this helps!

  • UI problem when run java swing application on MAC OSX

    Hello,
    I have problem when i run my java swing application on MAC OSX.
    Dialog box is not properly visible in MAC means ita size increses.
    its size incresed and and some content or buttons on that dialog are not fully visible.
    I can only see partial message or button.
    If any one have idea about this problem then give the solution.
    Thanks :)
    Shweta

    I am using following way to create dialog
    JOptionPane optionpane = new JOptionPane(new Object[]{lblMsgUp}, JOptionPane.OK_CANCEL_OPTION, JOptionPane.INFORMATION_MESSAGE, null, choices, "Save");
    JDialog dialog = optionpane.createDialog(parent, "Save");
    dialog.setSize(450, 125);
    dialog.setVisible(true);

  • Swing Applet on Mac OS 9

    I have a Swing applet and I deployed it in weblogic 6.1, when I access this in Mac os 9 , it gives the Applet error : closing in browser.
    Appart from installing MRJ2.2.5((latest?) and swingall.jar(jfc) ,
    what are the other necessary steps to get the VM running properly in this environment.
    But Apple's MRJ site states(http://developer.apple.com/java/download.html),
    New features introduced since MRJ 2.2 include:
    Full JFC Swing Support.
    Can a Mac expert out there give me an answer to whether or not a Mac OS 9 user can run an applet that uses Swing components.
    Please help.
    Thanks
    Vinod

    As per my knowledge, u can use JJEdit editor on MAC OS X. By using this editor, you can run the applets. Here I am using JJEdit as a java editor on MAC OS X. just dowload the JJEdit. and run the applet on it.
    regards
    nr konjeti

  • Why doesn't text in Java Swing applets show?

    See http://sambaker.com/econ/elast/elast.html
    This web page works OK on PCs.  Not on my MacBook Pro.  On my MacBook Pro, text is missing from some of the first Java applets on this page. 

    Be sure that the font color is different than the background color
    Increase the pt size in the tool's option bar beyond the presets. You can enter a number manually.

  • Swing Applet does not load on Mac OS 9

    Hello,
    I have written a Swing Applet. I deployed it in Apache TOMCAT and tried to access it using my iMac, running Mac OS 9. I have installed swingall.jar on my Mac so I have no problem running some sample Swing Applet from Sun's website. However, when I try to access my Swing applet, the following is shown in the "Java Messages" file:
    1/20/2003 @ 11:39:1
    An exception occurred:
    java.lang.ClassNotFoundException: com.my.package.gui.Main
    at com.apple.mrj.JManager.JMAppletClassLoader_IMPL.loadClass (JMAppletClassLoaderOld.java)
    at com.apple.mrj.JManager.JMAppletClassLoader_IMPL.loadClass(JMAppletClassLoaderOld.java)
    at com.apple.mrj.JManager.JMAppletClassLoader_ROOT.loadClass(JMAppletClassLoaderOld.java)
    at com.apple.mrj.JManager.JMAppletViewer_OLD.doLoadCode(JMAppletViewerOld.java)
    at com.apple.mrj.JManager.JMAppletViewer_OLD.setState(JMAppletViewerOld.java)
    at com.apple.mrj.JManager.JMViewerEvent.post(JMAppletViewerOld.java)
    at com.apple.mrj.JManager.AVDispatcherThread.run(JMAppletViewerOld.java)
    Does anyone have a clue? Please help.
    Thanks,
    A.A.

    aau2002 -- I have a simple applet using swing which I compiled with OSX, moved the class file to my desktop, installed the Swing stuff for OS 9.
    My html file is as follows:
    <HTML>
    <HEAD></HEAD>
    <BODY>
    <hr>
    <applet name="main applet" codebase="." code="DrawField.class" width=200 height=200 </applet>
    <hr>
    </BODY>
    </HTML>
    My applet never loads with the ClassNotFoundException
    I must not have correctly installed the swing stuff...
    Any suggestions? Thanks VERY much in advance.

  • Running a Java Applet on Mac OS browser

    I'm having trouble getting my Java Applet to work properly on the Mac OS version of IE5. Basicaly, the app fails to appear. Are there any do's and don'ts regarding the running of Java Applets on Mac Browsers?
    I read somewhere that you can't send parameters through to the Applet. Is that true? I'm not trying to do this and it's still doesn't work.
    Any help would be appreciated.

    If anyone can help me with this problem I would be greatful.

  • Need help for connecting Ms Acces with java Swing in Mac OS

    Hi all,
    i need to connect to Ms Access in MAc os through my java swing program.
    Is it possible for accessing Ms access through dsn in Mac OS.
    If Possible which driver shall i use for Establishing Connection with MS Access in Mac OS.
    Suggestion is needed urgently.
    Can anybody help me out regarding this..
    Thanks in advance.
    Regards,
    sreand

    if I don't find a better solution I'll try your 2nd option but what do you mean by "combo" update?
    My understanding is to simply insert the OS 10.5 installation CD, reinstall the OS and the just keep updating it via the OS SSoftware update panel and stop untill I see the scary Java 8 update. Is that what you meant?
    While you can do it that way, the combo update picks up operating system updates through a collection of releases. When dealing with operating system upgrades, I've found using the combo updates to be more reliable than Software Update, as sometimes Software Update doesn't apply updates correctly, and weird things can happen. Doesn't happen often though, thankfully.
    So the OS X 10.5.5 Combo update contains all updates between 10.5.0 and 10.5. The 10.5.8 combo update contains the updates from 10.5 thru 10.8. Here are the updates:
    10.5 combo update: http://support.apple.com/kb/DL692
    10.8 combo update: http://support.apple.com/kb/DL866
    If you go down the combo path, repair permissions before and after doing each update. Then do Software Update for any other non-OS X updates, and don't apply the Java Update 8.

  • Java applet in Mac OS

    Hello. There was a problem in applet under Mac OS. The problem is that if I call the dialog from an applet, then close the dialog applet does not receive the focus and have to again click on the applet.
    What can I do? Or should we write AppleScript applet to transfer the focus after the dialog is closed

    Oracle does not provide JRE for Mac OS X (at this moment).
    It may work better if you ask for advice on Apple's Java forum.

  • Memory Leak Java Plugin with Swing Applet

    Hi
    I experience the following problem and desperately need help on this. The Java Plugin (I use Version 1.3.1_02) seems to have a problem in printing Swing Applets.
    The problem can easily be reproduced (at least with NT):
    1) Start Internet Explorer or Netscape (I used 5.5/4.07)
    2) Launch the following demo swing applet
    http://java.sun.com/products/plugin/1.3.1_01a/demos/jfc/SwingSet2/SwingSet2Plugin.html
    3) Print the applet and observe (using task manager) the memory used by the browser process (the memory used by the process will increase every time you hit the print button but never decrease unless you shut down the browser)
    4) Print a couple of times (you may want to pause your print queue) and you will be able to crash your computer
    This seems to be the same bug reported with 4638742. However it says "in progress" for quite some time and I was wondering if some genious might know a work around for this.
    Cheers

    You might want to read an article about memory leaks in Java:
    http://www-106.ibm.com/developerworks/library/j-leaks/

  • PL/SQL and Java Swing interface

    Everybody in this forum knows that Oracle is the best database around
    with many functionalities, stability, performance, etc. We also know
    that PL/SQL is a great language to manipulate information directly
    in the database with many built in functions, OOP capability,
    transaction control, among other features. Today an application that
    manipulates information, which needs user interface, requires components
    to be developed using different technologies and normally running in
    different servers or machines. For example, the interface is done using
    a dynamic HTML generator like JSP, PHP, PL/SQL Web Toolkit, etc.
    This page is executed in an application server like Oracle iAS or
    Tomcat, just to name two, which in turn access a database like Oracle to
    build the HTML. Also rich clients like Java applets require an intermediate
    server to access the database (through servlets for example) although
    it is possible to access the database directly but with security issues.
    Another problem with this is that complexity increases a lot, many
    technologies, skills and places to maintain code which leads to a greater
    failure probability. Also, an application is constantly evolving, new
    calculations are added, new tables, changed columns. If you have an
    application with product code for example and you need to increase its
    size, you need to change it in the database, search for all occurrences
    of it in the middle-tier code and perhaps adjust interfaces. Normally
    there is no direct dependency among the tier components. On another
    issue, many application interfaces today are based on HTML which doesn't
    have interactive capabilities like rich-client interfaces. Although it
    is possible to simulate many GUI widgets with JavaScript and DHTML, it is
    far from the interactive level we can accomplish in rich clients like
    Java Swing, Flash MX, Win32, etc. HTML is also a "tag-based" language
    originally created to publish documents so even small pages require
    many bytes to be transmitted, far beyond of what we see on the screen.
    Even in fast networks you have a delay time to wait the page to be
    loaded. Another issue, the database is in general the central location
    for all kinds of data. Most applications relies on it for security,
    transaction and availability. My proposal is to use Oracle as the
    central location for interface, processing and data. With this approach
    we can create not only the data manipulation procedures in the database,
    but procedures that also control and manage user interfaces. Having
    a Oracle database as the central location for all components has many
    advantages:
    - Unique point of maintenance, backup and restore
    - Integrated database security
    - One language for everything, PL/SQL or Java (even both if desired)
    - Inherited database cache, transaction and processing optimizations
    - Direct access to the database dictionary
    - Application runs on Oracle which has support for many platforms.
    - Transparent use of parallel processing, clusters and future
    background technologies
    Regarding the interface, I already created a Java applet renderer
    which receives instructions from the database on how to create GUI
    objects and how to respond to events. The applet is only 8kb and can
    render any Swing or AWT object/event. The communication is done
    through HTTP or HTTPS using Oracles's MOD_PLSQL included in the Apache
    HTTP server which comes with the database or application server (iAS).
    I am also creating a database framework and APIs in PL/SQL to
    create and manipulate the client interface. The applet startup is
    very fast because it is very small, you don't need to download large
    classes with the client interface. Execution is done "on-demand"
    according to instructions received from the database. The instructions
    are very optimized in terms of network bandwidth and based on preliminary
    tests it can be up to 1/10 of a similar HTML screen. Less network usage
    means faster response and means that even low speed connections will
    have a good performance (a future development can be to use this in
    wireless devices like PDAs e even cell phones, just an idea for now).
    The applet can also be executed standalone by using Java Web Start.
    With this approach no business code, except the interface, is executed
    on the client. This means that alterations in the application are
    dynamically reflected in the client, no need to "re-download" the
    application. Events are transmitted when required only so network
    usage is minimized. It is also possible to establish triggering
    events to further reduce network usage. Since the protocol used is
    HTTP (which is stateless), the database framework I am creating will
    be responsible to maintain the state of connections, variables, locks
    and session information, so the developer don't need to worry about it.
    The framework will have many layers, from communication up to
    application so there will be pre-built functions to handle queries,
    pagination, lock, mail, log, etc. The final objective is to have a
    rich client application integrated into the database with minimum
    programming and maintenance requirements, not forgetting customization
    capabilities. Below is a very small example of what can de done. A
    desktop with two windows, each window with two fields, a button with an
    image to switch the values, and events to convert the typed text when
    leaving the field or double-clicking it. The "leave" event also has an
    optimization to only be triggered when the text changes. I am still
    developing the framework and adjusting the renderer but I think that all
    technical barriers were transposed by now. The framework is still in
    the early stages, my guess is that only 5% is done so far. As a future
    development even an IDE can be created so we have a graphical environment
    do develop applications. I am willing to share this with the PL/SQL
    community and listen to ideas and comments.
    Example:
    create or replace procedure demo1 (
    jre_version in varchar2 := '1.4.2_01',
    debug_info in varchar2 := 'false',
    compress_buffer in varchar2 := 'false',
    optimize_buffer in varchar2 := 'true'
    ) as
    begin
    interface.initialize('demo1_init','JGR Demo 1',jre_version,debug_info,compress_buffer,optimize_buffer);
    end;
    create or replace procedure demo1_init as
    begin
    toolkit.initialize;
    toolkit.create_icon('icon',interface.global_root_url||'img/switch.gif');
    toolkit.create_internal_frame('frame1','Frame 1',50,50,300,136);
    toolkit.create_label('frame1label1','frame1',10,10,50,20,'Field 1');
    toolkit.create_label('frame1label2','frame1',10,40,50,20,'Field 2');
    toolkit.create_text_field('frame1field1','frame1',50,10,230,20,'Field 1','Field 1',focus_event=>true,mouse_event=>true);
    toolkit.create_text_field('frame1field2','frame1',50,40,230,20,'Field 2','Field 2',focus_event=>true,mouse_event=>true);
    toolkit.set_text_field_event('frame1field1',toolkit.focus_lost_event,'demo1_set_upper',toolkit.get_text_method,'FIELD 1','false');
    toolkit.set_text_field_event('frame1field2',toolkit.focus_lost_event,'demo1_set_upper',toolkit.get_text_method,'FIELD 2','false');
    toolkit.set_text_field_event('frame1field1',toolkit.mouse_double_clicked_event,'demo1_set_lower',toolkit.get_text_method,'field 1','false');
    toolkit.set_text_field_event('frame1field2',toolkit.mouse_double_clicked_event,'demo1_set_lower',toolkit.get_text_method,'field 2','false');
    toolkit.create_button('button1','frame1',10,70,100,25,'Switch','Switch the values of "Field 1" and "Field 2"','S','icon');
    toolkit.set_button_event('button1',toolkit.action_performed_event,'demo1_switch_fields(''frame1field1'',''frame1field2'')','frame1field1:'||toolkit.get_text_method||',frame1field2:'||toolkit.get_text_method);
    toolkit.create_internal_frame('frame2','Frame 2',100,100,300,136);
    toolkit.create_label('frame2label1','frame2',10,10,50,20,'Field 1');
    toolkit.create_label('frame2label2','frame2',10,40,50,20,'Field 2');
    toolkit.create_text_field('frame2field1','frame2',50,10,230,20,'Field 1','Field 1',focus_event=>true,mouse_event=>true);
    toolkit.create_text_field('frame2field2','frame2',50,40,230,20,'Field 2','Field 2',focus_event=>true,mouse_event=>true);
    toolkit.set_text_field_event('frame2field1',toolkit.focus_lost_event,'demo1_set_upper',toolkit.get_text_method,'FIELD 1','false');
    toolkit.set_text_field_event('frame2field2',toolkit.focus_lost_event,'demo1_set_upper',toolkit.get_text_method,'FIELD 2','false');
    toolkit.set_text_field_event('frame2field1',toolkit.mouse_double_clicked_event,'demo1_set_lower',toolkit.get_text_method,'field 1','false');
    toolkit.set_text_field_event('frame2field2',toolkit.mouse_double_clicked_event,'demo1_set_lower',toolkit.get_text_method,'field 2','false');
    toolkit.create_button('button2','frame2',10,70,100,25,'Switch','Switch the values of "Field 1" and "Field 2"','S','icon');
    toolkit.set_button_event('button2',toolkit.action_performed_event,'demo1_switch_fields(''frame2field1'',''frame2field2'')','frame2field1:'||toolkit.get_text_method||',frame2field2:'||toolkit.get_text_method);
    end;
    create or replace procedure demo1_set_upper as
    begin
    toolkit.set_string_method(interface.global_object_name,toolkit.set_text_method,upper(interface.array_event_value(1)));
    toolkit.set_text_field_event(interface.global_object_name,toolkit.focus_lost_event,'demo1_set_upper',toolkit.get_text_method,upper(interface.array_event_value(1)),'false');
    end;
    create or replace procedure demo1_set_lower as
    begin
    toolkit.set_string_method(interface.global_object_name,toolkit.set_text_method,lower(interface.array_event_value(1)));
    toolkit.set_text_field_event(interface.global_object_name,toolkit.mouse_double_clicked_event,'demo1_set_lower',toolkit.get_text_method,lower(interface.array_event_value(1)),'false');
    end;
    create or replace procedure demo1_switch_fields (
    field1 in varchar2,
    field2 in varchar2
    ) as
    begin
    toolkit.set_string_method(field1,toolkit.set_text_method,interface.array_event_value(2));
    toolkit.set_string_method(field2,toolkit.set_text_method,interface.array_event_value(1));
    toolkit.set_text_field_event(field1,toolkit.focus_lost_event,'demo1_set_upper',toolkit.get_text_method,upper(interface.array_event_value(2)),'false');
    toolkit.set_text_field_event(field2,toolkit.focus_lost_event,'demo1_set_upper',toolkit.get_text_method,upper(interface.array_event_value(1)),'false');
    toolkit.set_text_field_event(field1,toolkit.mouse_double_clicked_event,'demo1_set_lower',toolkit.get_text_method,lower(interface.array_event_value(2)),'false');
    toolkit.set_text_field_event(field2,toolkit.mouse_double_clicked_event,'demo1_set_lower',toolkit.get_text_method,lower(interface.array_event_value(1)),'false');
    end;

    Is it sound like Oracle Portal?
    But you want to save a layer 9iAS.
    Basically, that was the WebDB.(Oracle changed the name to Portal when version 3.0)
    Over all, I agree with you.
    &gt;&gt;Having a Oracle database as the central location for all components has many
    &gt;&gt;advantages:
    &gt;&gt;
    &gt;&gt;- Unique point of maintenance, backup and restore
    &gt;&gt;- Integrated database security
    &gt;&gt;- One language for everything, PL/SQL or Java (even both if desired)
    &gt;&gt;- Inherited database cache, transaction and processing optimizations
    &gt;&gt;- Direct access to the database dictionary
    &gt;&gt;- Application runs on Oracle which has support for many platforms.
    &gt;&gt;- Transparent use of parallel processing, clusters and future
    &gt;&gt;background technologies
    I would like to build 'ZOPE' inside Oracle DB as a back-end
    Using Flash MX as front-end.
    Thomas Ku.

  • Unable to download images in a swing applet (1.3.1) behind proxy

    Hi
    One of my client have a proxy server and firewall and when they try to access my webserver
    then all the AWT applet are downloaded and rendered on client properly. However, the swing applet written
    using JDK 1.3.1 is downloaded and rendered but it doesn't display anything properly as images
    are not down loaded. I have used media tracker to add images to it like oMediaTracker.addImage( oImage, index );
    and then oMediaTracker.waitForAll();
    Java console display at client looks as follows:
    Java(TM) Plug-in: Version 1.3.1
    Using JRE version 1.3.1 Java HotSpot(TM) Client VM
    User home directory = C:\Documents and Settings\toy
    Proxy Configuration: no proxy
    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
    q: hide console
    s: dump system properties
    t: dump thread list
    x: clear classloader cache
    0-5: set trace level to <n>
    Applet Initialization start...
    Applet Image Initialization start...
    Trace level set to 5: basic, net, security, ext, liveconnect ... completed.
    Opening      http:MyServer/24/x.gif
    Connecting     http:MyServer/24/x.gif with no proxy
    Connecting
    http:MyServer/24/x.gif with cookie "ASPSESSIONIDGQGQQVWC=DLNBDAOABFANEPJFFIGOOIPG;
    JSESSIONID=25Ais2tF1eBkevUhAa2akocfShzNdzyL7yC1I7UhJl7Z6BLZrnQK!
    -1149265879"
    Opening      http:MyServer/40/y.gif
    Connecting      http:MyServer/40/y.gif with no proxy
    Connecting      http:MyServer/40/y.gif with cookie "ASPSESSIONIDGQGQQVWC=DLNBDAOABFANEPJFFIGOOIPG;
    JSESSIONID=25Ais2tF1eBkevUhAa2akocfShzNdzyL7yC1I7UhJl7Z6BLZrnQK!
    -1149265879"
    Opening     http://MyServer/sun/beans/infos/PanelBeanInfo.class
    Connecting     http://MyServer/sun/beans/infos/PanelBeanInfo.class with no proxy
    Connecting http://MyServer/sun/beans/infos/PanelBeanInfo.class with cookie "ASPSESSIONIDGQGQQVWC=DLNBDAOABFANEPJFFIGOOIPG;
    JSESSIONID=25Ais2tF1eBkevUhAa2akocfShzNdzyL7yC1I7UhJl7Z6BLZrnQK!
    -1149265879"
    Opening http://MyServer/java/awt/ContainerBeanInfo.class
    Connecting http://MyServer/java/awt/ContainerBeanInfo.class with no proxy
    Connecting http://MyServer/java/awt/ContainerBeanInfo.class
    Client machine tries to access these images but i never receive a call at web server end when i see
    IIS log.
    CLient environment:
    -Windows 2000/XP/NT
    -Internet explorer 6.0 SP1 or IE 5.5 SP2
    with connection->LAN Setting->Use Automatic configuration script(only checked)
    -Java Plugin configured like proxies->Use Browser Setting
    -JDK 1.3.1 plug in at client(downloaded and Installed automatically on demand)
    -Object tag used to download applet and plugin
    -Firewall and proxy(i don't know about vendor)
    My webserver environment
    Windows 2000/iis 5.0 with anonymous authentication and
    cache-control header set to no-store (so that proxy doesn't cache anything)
    QUESTIONS:
    ~~~~~~~~~
    Q.1. When i try from home network that has a proxy then everything works fine. At client site everything except
    image download works fine. I mean jars are downloaded and i can see anything drawn using JAVA API.
    When i try from home i see following java console trace
    Java(TM) Plug-in: Version 1.3.1
    Using JRE version 1.3.1 Java HotSpot(TM) Client VM
    User home directory = C:\Documents and Settings\wuko
    Proxy Configuration: Automatic Proxy Configuration
    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
    q: hide console
    s: dump system properties
    t: dump thread list
    x: clear classloader cache
    0-5: set trace level to <n>
    Trace level set to 5: basic, net, security, ext, liveconnect ... completed.
    Applet Initialization start...
    Applet Image Initialization start...
    Opening http://MyServer/24/connec.gif
    Connecting http://MyServer/24/connec.gif with proxy=197.168.1.100:808
    Connecting http://MyServer/24/connec.gif with cookie "ASPSESSIONIDQQGQQCYU=GBJFAOABCJFPDMGFHEKLDACA; JSESSIONID=26yu5m1b4upVuXoAoDmtMbWXQmetQpyzqjFANszo9vFubujT4qGX!-1149265879"
    Opening http://MyServer/24/cool.gif
    Connecting http://MyServer/24/cool.gif with proxy=197.168.1.100:808
    Connecting http://MyServer/24/cool.gif with cookie "ASPSESSIONIDQQGQQCYU=GBJFAOABCJFPDMGFHEKLDACA; JSESSIONID=26yu5m1b4upVuXoAoDmtMbWXQmetQpyzqjFANszo9vFubujT4qGX!-1149265879"
    etc
    I can't set the plugin at client to use automatic script just like IE browser uses. This option is not supported in JRE1.3.1. Looks to be supported in JRE1.4.1. My client doesn't want to set manual proxy ip and port in plugin as they don't want to reveal this info to everyone within the company for security reason.
    Q.2. Why some classes like PanelBeanInfo.class, JAppletBeanInfo.class are downloaded
    from my server while it doesn't exist at my webserver. Any thing stupid IE or plugin doing
    at client. Any Idea?
    Thanks in advance for any help.
    Ratan

    Thanks to Mike and other friends who already replied on this topic.
    Here is my research analysis:
    Answer to Question 1:
    ~~~~~~~~~~~~~~~~~~~~~
    The solution is to bundle all the images with JAR. Bundle with jar whichever needs it. However, it might require duplicacy.
    Image img = null;
    try
    img = Toolkit.getDefaultToolkit().getImage(getClass().getResource(fileName));
    catch (Exception e) { }
    In this case make sure that you have image at the same location where you access it. For example if you have to access an image in package class com.awt.ui.MyClass then your image should also be at location ..\com\awt\ui
    Note: It will require image duplicacy in your JAR but it solves the problem. It gives the advantage of fewer download from server.
    Answer to Question 2:
    ~~~~~~~~~~~~~~~~~~~~~
    IE treats applet as an active-X and try to look for these classes in your JAR. SUN has stopped its support in JDK1.3.1 and plus. What one can do is to create dummy classes with these names and bundle it with your JAR. You have to create these dummy classes if you enable Basic authentication on your web server then browser will try to look for these classes on the server and continue to prompt you for login and password. It might bother your customer un-necessarily to enter login and password too many times prompted by plug-in (plug in).
    --Ratan                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • How to run swing applets in a browser??

    I understand it is a typical question and there lot of articles on it. I tried but am confused. I installed JRE1.3 which has java plug-in along with it which supports swing applets in a browser.Once i got that plug in i also downloaded html converter but am confused how should i run my swing applet.Can anyone please explain in simple steps as to how to achieve this objective..Thanks much in advance..an example would be of real big help
    Thanks

    The below links will help you.
    http://java.sun.com/products/plugin//1.3/docs/index.docs.html
    http://java.sun.com/products/plugin/1.3/plugin.faq.html

  • Best IDE and how-to create HTML for a swing Applet

    Can you help me out? I've been using, and teaching with the old Symantec VisualCafe product from long, long, ago. It still works fine & I can even use it to build JFC/Swing Applets etc. But a few things have occurred. For one, a way back, Symantec sold VisualCafe to WEBGAIN - who now has gone out of business and sold it to a company called TOGETHERSOFT - who doesn't support it any longer.
    This isn't really a big deal to me, because I can still build and deploy applets that are pre-swing easily enough. (as can my students)
    HOWEVER... I'd like to be running with the LATEST Java (I think it's 1.4.01) and I'd LIKE to use whatever is the best development environment I can use - especially one I can recommend to my students. Do you know what that should be?
    What's more, I'd still like to take some JFC/Swing created applets (even if compiled with the older VisualCafe IDE) and generate the HTML to allow 1.4 enabled browsers to run them (this is the case for the schools versions of Explorer and Netscape). Now, the HTML I have INSTALLED for the students used the HTML converter - back in 1.2 to produce the HTML at the bottom of this. This code no longer works now with current browsers. Do you know HOW one makes a jfc/swing compiled applet run on the latest browsers?
    Any help or direction you can give would be appreciated.
    thanks,
    Bobby Berns
    [email protected]
    <OBJECT classid="clsid:8AD9C840-044E-11D1-B3E9-00805F499D93"
    WIDTH = 756 HEIGHT = 396 codebase="http://java.sun.com/products/plugin/1.2/jinstall-12-win32.cab#Version=1,2,0,0">
    <PARAM NAME = CODE VALUE = "lottery.class" >
    <PARAM NAME="type" VALUE="application/x-java-applet;version=1.2">
    <COMMENT>
    <EMBED type="application/x-java-applet;version=1.2" java_CODE = "lottery.class" WIDTH = 756 HEIGHT = 396 pluginspage="http://java.sun.com/products/plugin/1.2/plugin-install.html"><NOEMBED></COMMENT>
    </NOEMBED></EMBED>
    </OBJECT>
    <!--
    <APPLET CODE = "lottery.class" WIDTH = 756 HEIGHT = 396 >
    </APPLET>
    -->
    <!--"END_CONVERTED_APPLET"-->

    Bobby,
    It's been a while since I've used the HTML Converter, but if I had to guess I'd say you need a newer version than what you have. Also, doesn't the converter allow you to choose which JDK you want to use (in which case you could select 1.4)? Again it's been a while so bear with me. Another option would be to put all the Swing classes into a .jar file (typically called swingall.jar) on your server and include that file as an attribute in your applet tag like this:
    <APPLET CODE="yourApplet.class" ARCHIVE="swingall.jar">
    This way you don't have to use the Java Plug-in, however the initial download time of the .jar file can be significant.
    As for an IDE, I've always been happy using a text editor like UltraEdit. However, I've heard good things about Forte, and hey, it's free!
    Regarding Christina's post, that solution will only work if the Applet does not use Swing components (and Bobby specifically said it does). By using the <OBJECT> and <EMBED> tags, rather than the <APPLET> tag, you force the browser to use the Java Plug-in (rather than the browser's default JVM).
    Hope that helps,
    - Sheepy

  • How to load a java card applet into a java card

    Dear All,
    I am a novice to java card technology..
    I have done some search on how to load a java card applet into a smart card but haven't found a satisfactory answer. I have read about installer.jar and scriptgen tool but I want to load the applet from a java program and not from command line. It would be of great help if somebody can help me out.
    If somebody can share a sample program which load a javacard applet(.CAP file) into a smart card, I will be very thankful.
    I am able to find some client applications which help us send APDU commands and recieve response APDU's to interact with an applet loaded on to the smart card but not application which actually load the applet.
    I have heard of OCF and GP.. some say that OCF technology is outdated and no longer in use.. can somebosy throw some light on this too..
    cheers,
    ganesh

    hi siavash,
    thanks for the quick response.. i checked out GPShell as suggested, it looked like a tool by which one can load an applet on to card and send some sample apdu commands... but I want to load the applet from the code.
    My application should look something like this.. it will be a swing applicaton where I have a drop down with a list of readers, I select the one desired and then click on "LOAD" after inserting a blank java card, at this point my applet which is stored in my DB should get loaded on to the java card. The next step should be to personalize it where I enter the values for the static variables of my applet and click "PERSONALIZE", at this point all these values should be embedded into APDU commands and sent to the java card for processing.
    For achieving this I am yet to find a comprehensive sample or documentation on the net.
    Please help...
    regards,
    ganesh

Maybe you are looking for

  • How can I configure Home Sharing to work through a consumer VPN service?

    I recently purchased a year subscription to a VPN service know as Private Intenet Access (PIA). With this VPN executable program connected to it's servers, my data is "filtered" through it behind the router. The router IS NOT configure with the vpn s

  • How to get the real path of the xml file

    I have a java application following is the package structure com>>gts>>xml having file---------> MyXML.xml com>>gts>>java having java program to read the file Problem is if I use File file = new File("..\\xml\\MyXML.xml"); java.io.FileNotFoundExcepti

  • IPhone 4 from Apple store in Germany (Oberhausen) NOT UNLOCKED !

    i have iPhone 4 factory unlocked, then i travelled to germany and my iphone had some problems so i went to the nearest Apple Store in Germany (Oberhausen) and the Genius Bar told me that my iPhone can't be repaired and out of warranty so they told me

  • Elan Sayso/Tempo Multimedia TTS? - Ipod wont work with itunes

    What does this mean? I can put my itunes on fine and I can plug in my ipod nano 16gb...but seperately only. If I have itunes on and plug in my ipod then 'Elan Sayso/Tempo Multimedia TTS Server has stopped working' and I have to shut down itunes as it

  • Connector Specific Error

    I am trying to sync with my Outlook and I keep getting an error that says "Connector specific error"  I get this same error using the USB cable and my bluetooth.  Can someone please help?!